[Issue 10076] expression.c:4310: virtual Expression* TypeExp::semantic(Scope*): Assertion `0' failed.
http://d.puremagic.com/issues/show_bug.cgi?id=10076 --- Comment #3 from Kenji Hara 2013-05-13 23:27:46 PDT --- > Here's a dustmine reduced testcase. Run with `dmd -unittest`. Thanks. AFAICS This is a regreession from 2.060. This reduced code (Use old alias syntax): void main() { string s; validate(s); } template getValidaterAttrs(T) { alias getMembersAndAttributesWhere!().Elements getValidaterAttrs; } void validate(T)(T) { alias getValidaterAttrs!T memberAttrs; auto x = memberAttrs.length; } Fails without assertion in 2.059: test.d(8): Error: template instance getMembersAndAttributesWhere!() template 'getMembersAndAttributesWhere' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(12): Error: template instance test.getValidaterAttrs!(string) error instantiating test.d(4):instantiated from here: validate!(string) test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(12): Error: forward reference to 'getMembersAndAttributesWhere!().Elements' test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(12): Error: forward reference to 'getMembersAndAttributesWhere!().Elements' test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(13): Error: forward reference to 'getMembersAndAttributesWhere!().Elements' test.d(13): Error: getValidaterAttrs!(string) is used as a type test.d(4): Error: template instance test.validate!(string) error instantiating But cause an ice in 2.060: test.d(8): Error: template instance getMembersAndAttributesWhere!() template 'getMembersAndAttributesWhere' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(12): Error: template instance test.getValidaterAttrs!(string) error instantiating test.d(4):instantiated from here: validate!(string) test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(12): Error: forward reference to 'getMembersAndAttributesWhere!().Elements' test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(12): Error: forward reference to 'getMembersAndAttributesWhere!().Elements' test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(8): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!().Elements' is not defined test.d(13): Error: forward reference to 'getMembersAndAttributesWhere!().Elements' Assertion failure: '0' on line 4216 in file 'expression.c' abnormal program termination -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10076] expression.c:4310: virtual Expression* TypeExp::semantic(Scope*): Assertion `0' failed.
http://d.puremagic.com/issues/show_bug.cgi?id=10076 --- Comment #2 from simendsjo 2013-05-13 23:04:28 PDT --- Here's a dustmine reduced testcase. Run with `dmd -unittest`. unittest { string s; validate(s); } template getValidaterAttrs(T) { alias getValidaterAttrs = getMembersAndAttributesWhere!().Elements; } string[] validate(T)(T ) { alias memberAttrs = getValidaterAttrs!T; if(!memberAttrs.length) return ; } -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10079] New: Builit-in generated opAssign should be pure nothrow @safe in default
http://d.puremagic.com/issues/show_bug.cgi?id=10079 Summary: Builit-in generated opAssign should be pure nothrow @safe in default Product: D Version: D2 Platform: All OS/Version: All Status: NEW Keywords: rejects-valid Severity: major Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: k.hara...@gmail.com --- Comment #0 from Kenji Hara 2013-05-13 20:49:44 PDT --- If a struct has postblit or destructor, assignment is automatically implemented with swap-and -destroy.. struct S { this(this) {} // or ~this() } void main() { S s1, s2; s1 = s2; // is equivalent to // auto tmp = s2 // bitwise copy // swap(s1, tmp); // bitwise swap // destroy tmp;// destroy old state of s1 } The bitwise copy and swap are pure, nothrow and @safe. But currently this code doesn't work. struct S { this(this) pure nothrow @safe {} // and/or ~this() pure nothrow @safe {} } void main() pure nothrow @safe { S s1, s2; s1 = s2; } test.d(7): Error: pure function 'D main' cannot call impure function 'test.S.opAssign' test.d(7): Error: safe function 'D main' cannot call system function 'test.S.opAssign' test.d(7): Error: s1.opAssign is not nothrow test.d(5): Error: function D main 'main' is nothrow yet may throw -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10005] struct variable declaration and const-correctness
http://d.puremagic.com/issues/show_bug.cgi?id=10005 Walter Bright changed: What|Removed |Added Status|NEW |RESOLVED CC||bugzi...@digitalmars.com Resolution||FIXED -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10005] struct variable declaration and const-correctness
http://d.puremagic.com/issues/show_bug.cgi?id=10005 --- Comment #2 from github-bugzi...@puremagic.com 2013-05-13 17:52:14 PDT --- Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/a7a1eb4f31efbe3e8fa4023c1a32486ffd49eb46 fix Issue 10005 - struct variable declaration and const-correctness https://github.com/D-Programming-Language/dmd/commit/4ed3396c2cd6651695f07fc20c614a3e02701bc7 Merge pull request #1948 from 9rnsr/fix10005 Issue 10005 - struct variable declaration and const-correctness -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10047] opDispatch instantiation failure should be gagged for UFCS
http://d.puremagic.com/issues/show_bug.cgi?id=10047 --- Comment #3 from github-bugzi...@puremagic.com 2013-05-13 17:46:13 PDT --- Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/e61d989b600588269a91d0aaaff557890df7233d fix Issue 10047 - opDispatch instantiation failure should be gagged for UFCS https://github.com/D-Programming-Language/dmd/commit/6daf3cc2a595e053d0bede7d0cc264cc2eb704ce Merge pull request #1981 from 9rnsr/fix10047 [REG2.063a] Issue 10047 - opDispatch instantiation failure should be gagged for UFCS -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10047] opDispatch instantiation failure should be gagged for UFCS
http://d.puremagic.com/issues/show_bug.cgi?id=10047 Walter Bright changed: What|Removed |Added Status|NEW |RESOLVED CC||bugzi...@digitalmars.com Resolution||FIXED -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10076] expression.c:4310: virtual Expression* TypeExp::semantic(Scope*): Assertion `0' failed.
http://d.puremagic.com/issues/show_bug.cgi?id=10076 --- Comment #1 from Kenji Hara 2013-05-13 17:09:20 PDT --- Where is the test case? -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10078] New: std.string.indexOf(Char[], dchar, CaseSensitive) fails at compile time
http://d.puremagic.com/issues/show_bug.cgi?id=10078 Summary: std.string.indexOf(Char[], dchar, CaseSensitive) fails at compile time Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: Phobos AssignedTo: nob...@puremagic.com ReportedBy: mich...@overuse.org --- Comment #0 from Mike Houston 2013-05-13 16:44:16 PDT --- Created an attachment (id=1213) Patch to indexOf to avoid calling memchr DMD 2.062 OS X If the std.string.indexOf(Char[], dchar, CaseSensitive) method is called at compile time with an ASCII dchar, it will fail: /usr/share/dmd/src/phobos/std/string.d(345): Error: memchr cannot be interpreted at compile time, because it has no available source code Test case: import std.stdio; import std.string; int index = indexOf("xyz", cast(dchar) 'x'); // Fails compile int index1 = indexOf("xyz", cast(dstring) "x"); // Succeeds void main() { writeln("indexOf(\"xyz\", \"x\") = ", index); } Patch: I've modified the string.d implementation to avoid calling memchr. In that branch of the code, I have inserted a modified version of the case-insensitive version of the search loop. Diff file attached against the source included in the 2.0.62 distribution. Regards, Mike. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 6082] Constructors of templated types should be callable via IFTI
http://d.puremagic.com/issues/show_bug.cgi?id=6082 --- Comment #1 from Steven Schveighoffer 2013-05-13 15:54:21 PDT --- Also see DIP 40: http://wiki.dlang.org/DIP40 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10077] add pragma(mangle, "...") to override symbol mangle.
http://d.puremagic.com/issues/show_bug.cgi?id=10077 Igor Stepanov changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED --- Comment #1 from Igor Stepanov 2013-05-13 14:07:03 PDT --- Fixed in pull https://github.com/D-Programming-Language/dmd/pull/2024 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10077] New: add pragma(mangle, "...") to override symbol mangle.
http://d.puremagic.com/issues/show_bug.cgi?id=10077 Summary: add pragma(mangle, "...") to override symbol mangle. Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: enhancement Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: wazar.leoll...@yahoo.com --- Comment #0 from Igor Stepanov 2013-05-13 14:05:49 PDT --- Usage: pragma(mangle, "__TEST__") extern int test; //test.mangleof == "__TEST__" pragma(mangle, "__FOO__") int foo() { return 0; } //foo.mangleof == "__FOO__" -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10076] New: expression.c:4310: virtual Expression* TypeExp::semantic(Scope*): Assertion `0' failed.
http://d.puremagic.com/issues/show_bug.cgi?id=10076 Summary: expression.c:4310: virtual Expression* TypeExp::semantic(Scope*): Assertion `0' failed. Product: D Version: D2 Platform: x86_64 OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: simend...@gmail.com --- Comment #0 from simendsjo 2013-05-13 13:54:46 PDT --- Using dmd 2.062 on GNU/Linux Arch x64. Haven't tried other setups. Running dustmite now, but it looks like it might take a while. source/simendlib/validate.d(69): Error: template instance getMembersAndAttributesWhere!(string, isValidationAttr) getMembersAndAttributesWhere!(string, isValidationAttr) does not match template declaration getMembersAndAttributesWhere(alias T, alias Pred) source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(73): Error: template instance simendlib.validate.getValidaterAttrs!(string) error instantiating source/simendlib/validate.d(31):instantiated from here: validate!(string) source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(73): Error: forward reference to 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(73): Error: forward reference to 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(69): Error: identifier 'Elements' of 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' is not defined source/simendlib/validate.d(74): Error: forward reference to 'getMembersAndAttributesWhere!(string, isValidationAttr).Elements' dmd: expression.c:4310: virtual Expression* TypeExp::semantic(Scope*): Assertion `0' failed. Error: Build command failed with exit code -6 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10075] New: type inferred const as template value parameter fails when forward-referenced
http://d.puremagic.com/issues/show_bug.cgi?id=10075 Summary: type inferred const as template value parameter fails when forward-referenced Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: clugd...@yahoo.com.au --- Comment #0 from Don 2013-05-13 09:26:13 PDT --- struct fd_custom(int XET) { int[XET] fd_array; } fd_custom!(FD_SETSZ) fdxxx; const FD_SETSZ = 4; bug.d(6): Error: fd_custom!(4) had previous errors It's not running semantic() on the forward-referenced variable before attempting to use its value. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10063] inout+pure results in ability to produce immutable reference to mutable data
http://d.puremagic.com/issues/show_bug.cgi?id=10063 --- Comment #1 from github-bugzi...@puremagic.com 2013-05-13 07:46:50 PDT --- Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/0dc34e8bf8dcbb7a16f4de197b902e83cbb21306 fix Issue 10063 - inout+pure results in ability to produce immutable reference to mutable data https://github.com/D-Programming-Language/dmd/commit/3d7f0374d99f94307e5dd3694594ac3b172ecbae Merge pull request #2031 from 9rnsr/fix10063 Issue 10063 - inout+pure results in ability to produce immutable reference to mutable data -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 9539] Wrong implicit conversion of array to pointer
http://d.puremagic.com/issues/show_bug.cgi?id=9539 Andrej Mitrovic changed: What|Removed |Added CC||kyfo...@gmail.com --- Comment #8 from Andrej Mitrovic 2013-05-13 06:51:28 PDT --- *** Issue 10072 has been marked as a duplicate of this issue. *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10072] Array copy broken for array of pointers
http://d.puremagic.com/issues/show_bug.cgi?id=10072 Andrej Mitrovic changed: What|Removed |Added Status|NEW |RESOLVED CC||andrej.mitrov...@gmail.com Resolution||DUPLICATE --- Comment #1 from Andrej Mitrovic 2013-05-13 06:51:28 PDT --- Fixed in git-head, Issue 9539 was the report. *** This issue has been marked as a duplicate of issue 9539 *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 9531] __traits(parent, ...) does not work for types defined within a unittest block
http://d.puremagic.com/issues/show_bug.cgi?id=9531 --- Comment #3 from Andrej Mitrovic 2013-05-13 06:40:57 PDT --- Strange, this seems to have been fixed in git-head. Anyone know which pull did it? -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10049] Spurious "Label already defined" error inside a foreach over a range aggregate
http://d.puremagic.com/issues/show_bug.cgi?id=10049 Kenji Hara changed: What|Removed |Added CC||c...@dawg.eu --- Comment #3 from Kenji Hara 2013-05-13 05:38:07 PDT --- *** Issue 9973 has been marked as a duplicate of this issue. *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 9973] ICE for selective import in compiler generated try finally body
http://d.puremagic.com/issues/show_bug.cgi?id=9973 Kenji Hara changed: What|Removed |Added Status|NEW |RESOLVED Resolution||DUPLICATE --- Comment #1 from Kenji Hara 2013-05-13 05:38:07 PDT --- The root cause was just same as bug 10049. So the bug is now fixed in 2.063a. *** This issue has been marked as a duplicate of issue 10049 *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10074] New: segfault in dmd
http://d.puremagic.com/issues/show_bug.cgi?id=10074 Summary: segfault in dmd Product: D Version: unspecified Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: jens.k.muel...@gmx.de --- Comment #0 from jens.k.muel...@gmx.de 2013-05-13 05:15:50 PDT --- The following program causes dmd (dmd2.062) to segfault on Linux. template foo(F) { enum foo = false; } bool foo(F)(F f) if (foo!F) { return false; } void main() { foo(1); } $ dmd test.d segmentation fault dmd test.d I expect the program to compile or abort with an error but there should be no segfault. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 8081] pure nothrow unittest problem in generated 'header' file
http://d.puremagic.com/issues/show_bug.cgi?id=8081 bearophile_h...@eml.cc changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 6453] Allow multiple invariant per struct/class
http://d.puremagic.com/issues/show_bug.cgi?id=6453 Kenji Hara changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 9628] Lambda in foreach loop Vs. lambda in static foreach loop
http://d.puremagic.com/issues/show_bug.cgi?id=9628 Kenji Hara changed: What|Removed |Added Keywords||pull Platform|x86 |All OS/Version|Windows |All --- Comment #2 from Kenji Hara 2013-05-13 02:39:52 PDT --- https://github.com/D-Programming-Language/dmd/pull/2029 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---
[Issue 10073] Default opEquals depends on class declaration order with DMD HEAD
http://d.puremagic.com/issues/show_bug.cgi?id=10073 Kenji Hara changed: What|Removed |Added Keywords||pull, rejects-valid --- Comment #1 from Kenji Hara 2013-05-13 02:36:18 PDT --- https://github.com/D-Programming-Language/dmd/pull/2025 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because: ---