digitalmars.D.bugs - [Issue 3779] New: ["123"][0][$-1] causes __dollar unresolved in compile-time.
- d-bugmail puremagic.com (44/44) Feb 07 2010 http://d.puremagic.com/issues/show_bug.cgi?id=3779
- d-bugmail puremagic.com (10/10) Feb 07 2010 http://d.puremagic.com/issues/show_bug.cgi?id=3779
- d-bugmail puremagic.com (11/11) Feb 07 2010 http://d.puremagic.com/issues/show_bug.cgi?id=3779
- d-bugmail puremagic.com (16/16) Jun 08 2010 http://d.puremagic.com/issues/show_bug.cgi?id=3779
- d-bugmail puremagic.com (11/11) Apr 23 2011 http://d.puremagic.com/issues/show_bug.cgi?id=3779
- d-bugmail puremagic.com (11/11) Apr 30 2011 http://d.puremagic.com/issues/show_bug.cgi?id=3779
http://d.puremagic.com/issues/show_bug.cgi?id=3779 Summary: ["123"][0][$-1] causes __dollar unresolved in compile-time. Product: D Version: 2.041 Platform: Other OS/Version: Mac OS X Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: kennytm gmail.com Consider the following sniplet: ---------------------------------------------------------- template E(){ enum E=["123"][0][$-1]; } pragma(msg, E!()); import std.stdio; void main() { writeln(E!()); } ---------------------------------------------------------- Compiling with "dmd" (r287) gives: ---------------------------------------------------------- (["123"][0u])[__dollar - 1u] Undefined symbols: "_D1a6__T1EZ8__dollark", referenced from: _D1a6__T1EZ8__dollark$non_lazy_ptr in a.o (maybe you meant: _D1a6__T1EZ8__dollark$non_lazy_ptr) ld: symbol(s) not found collect2: ld returned 1 exit status --- errorlevel 1 ---------------------------------------------------------- where the expected output from the compiler should be: ---------------------------------------------------------- '3' ---------------------------------------------------------- and links the binary successfully. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Feb 07 2010
http://d.puremagic.com/issues/show_bug.cgi?id=3779 A simpler test case is import std.stdio; enum E=["123"][0][$-1]; void main() { writeln(E); } No templates required. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Feb 07 2010
http://d.puremagic.com/issues/show_bug.cgi?id=3779 Don <clugdbug yahoo.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |clugdbug yahoo.com.au Should the title be '... unresolved at link time' ? If so, it applies to Windows as well. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Feb 07 2010
http://d.puremagic.com/issues/show_bug.cgi?id=3779 Don <clugdbug yahoo.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |link-failure, rejects-valid OS/Version|Mac OS X |All Even simpler test case: ---- static const E=["123"][0][$-1]; ---- bug.d(1): Error: non-constant expression (["123"][0u])[__dollar - 1u] This is a constant-folding issue. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jun 08 2010
http://d.puremagic.com/issues/show_bug.cgi?id=3779 Walter Bright <bugzilla digitalmars.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |bugzilla digitalmars.com 15:49:56 PDT --- D1 Fix: https://github.com/D-Programming-Language/dmd/commit/da0159d02d0e4ecb7ad1afa4bc6da402e677846f -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Apr 23 2011
http://d.puremagic.com/issues/show_bug.cgi?id=3779 kennytm gmail.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED Fixed on D2 as well. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Apr 30 2011