Thread overview
[Issue 9171] New: error optimization of expression
Dec 17, 2012
Syava Dee
Dec 17, 2012
Syava Dee
Dec 17, 2012
Don
Dec 18, 2012
Walter Bright
Dec 18, 2012
Walter Bright
December 17, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171

           Summary: error optimization of expression
           Product: D
           Version: D2
          Platform: x86
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: syavadee@gmail.com


--- Comment #0 from Syava Dee <syavadee@gmail.com> 2012-12-17 02:10:14 PST ---
Created an attachment (id=1169)
source file showing problem

$ dmd -O bug.d && ./bug
nobug:
r=0111000000000000000100000000000000000000000000000000
z=0000000000000000000010000000000000000000000000000000
bug:
r=0111000000000000000100000000000000000000000000000000
z=0000000000000000000000000000000000000000000000000000
#                     ^
this wrong

$ dmd bug.d && ./bug
nobug:
r=0111000000000000000100000000000000000000000000000000
z=0000000000000000000010000000000000000000000000000000
bug:
r=0111000000000000000100000000000000000000000000000000
z=0000000000000000000010000000000000000000000000000000
#                     ^
this ok

dmd 2.060, ubuntu 12.04 and windows xp

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 17, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171


Syava Dee <syavadee@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |critical


-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 17, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171



--- Comment #1 from Don <clugdbug@yahoo.com.au> 2012-12-17 07:34:34 PST ---
Works for me on git head.
Could be a duplicate of bug 8840.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171



--- Comment #2 from github-bugzilla@puremagic.com 2012-12-17 18:14:19 PST ---
Commit pushed to dmd-1.x at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/118d3da3a9b35911afbf2eae98084f75c33802f3 fix Issue 9171 - error optimization of expression

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171



--- Comment #3 from github-bugzilla@puremagic.com 2012-12-17 18:14:24 PST ---
Commit pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/d4b885b88675cfdde0f1e8c92d94797d41e077ea fix Issue 9171 - error optimization of expression

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171


Walter Bright <bugzilla@digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |bugzilla@digitalmars.com
         Resolution|                            |FIXED


--- Comment #4 from Walter Bright <bugzilla@digitalmars.com> 2012-12-17 18:15:00 PST ---
This bug has been there for over 15 years.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171


hsteoh@quickfur.ath.cx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hsteoh@quickfur.ath.cx


--- Comment #5 from hsteoh@quickfur.ath.cx 2012-12-17 18:41:18 PST ---
Scary. Confirms that old adage about non-trivial software being never actually bug-free.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171


Walter Bright <bugzilla@digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|D2                          |D1 & D2


--- Comment #6 from Walter Bright <bugzilla@digitalmars.com> 2012-12-17 20:55:17 PST ---
To be fair, triggering this requires a very rare confluence of seemingly random and unrelated things, which is why it hasn't been reported before. It's appearance now suggests an expanding user base for D.

Anyhow, I like to put a high priority on fixing these kinds of issues because they can be very frustrating and demoralizing to users.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 18, 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9171



--- Comment #7 from hsteoh@quickfur.ath.cx 2012-12-17 21:01:34 PST ---
Another frustrating one is the template cross-talk one, bug 8542. It discouraged me from writing too much functional-style code, for fear that I might run into it again.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------