digitalmars.D.bugs - [Issue 1950] New: CTFE doesn't work correctly for structs passed by ref
- d-bugmail puremagic.com (29/29) Mar 26 2008 http://d.puremagic.com/issues/show_bug.cgi?id=1950
- d-bugmail puremagic.com (12/12) Aug 17 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1950
- d-bugmail puremagic.com (8/8) Aug 21 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1950
- d-bugmail puremagic.com (10/10) Aug 25 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1950
- d-bugmail puremagic.com (12/12) Sep 03 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1950
http://d.puremagic.com/issues/show_bug.cgi?id=1950 Summary: CTFE doesn't work correctly for structs passed by ref Product: D Version: 2.012 Platform: PC OS/Version: Windows Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: bugzilla digitalmars.com ReportedBy: samukha voliacable.com struct S { int x; } int foo() { S s; bar(s); return s.x; } void bar(ref S s) { s.x = 10; } enum x = foo(); static assert(x == 10); // Fails, x is 0 --
Mar 26 2008
http://d.puremagic.com/issues/show_bug.cgi?id=1950 Don <clugdbug yahoo.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |clugdbug yahoo.com.au Version|2.012 |1.020 This bug also applies to D1.0, replacing the 'enum' with const int x = foo(); -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 17 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1950 I have fixed this in my copy of interpret.c, but it's rather more general. It allows arbitrary expressions as reference parameters. (Passing an array member by reference will result in wrong-code in DMD1.046). -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 21 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1950 Don <clugdbug yahoo.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |patch I have sent Walter my patch for this, it will be in the next release. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 25 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1950 Walter Bright <bugzilla digitalmars.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |bugzilla digitalmars.com Resolution| |FIXED 13:23:39 PDT --- Fixed dmd 1.047 and 2.032 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Sep 03 2009