digitalmars.D.bugs - [Issue 6765] New: [CTFE]: AA.length doesn't compile when AA is null
- d-bugmail puremagic.com (31/31) Oct 04 2011 http://d.puremagic.com/issues/show_bug.cgi?id=6765
- d-bugmail puremagic.com (13/13) Oct 04 2011 http://d.puremagic.com/issues/show_bug.cgi?id=6765
http://d.puremagic.com/issues/show_bug.cgi?id=6765 Summary: [CTFE]: AA.length doesn't compile when AA is null Product: D Version: D1 & D2 Platform: Other OS/Version: Windows Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: clugdbug yahoo.com.au --- Comment #0 from Don <clugdbug yahoo.com.au> 2011-10-04 05:53:43 PDT --- At compile time, if an AA is null, then AA.length is zero. int main() { int[int] w; return w.length; // OK } But: static assert({ int[int] w; return w.length; }()==0); fails with: \..\src\druntime\import\object.di(362): Error: _aaLen cannot be interpreted at compile time, because it has no available source code Both D1 and D2. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Oct 04 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6765 Walter Bright <bugzilla digitalmars.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |bugzilla digitalmars.com Resolution| |FIXED --- Comment #1 from Walter Bright <bugzilla digitalmars.com> 2011-10-04 16:39:53 PDT --- https://github.com/D-Programming-Language/dmd/commit/51d83859ec2440f90ca1625640358502372b1465 https://github.com/D-Programming-Language/dmd/commit/411fdb0f7b391a028d40ec888b63d44ebcb646bb -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Oct 04 2011