http://d.puremagic.com/issues/show_bug.cgi?id=5908


kenn...@gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Optimizer generates wrong   |Optimizer generates wrong
                   |value with floating-point   |value with divide-by-zero.
                   |divide-by-zero.             |


--- Comment #1 from kenn...@gmail.com 2011-04-29 00:36:35 PDT ---
Actually the whole divide-by-zero scene is broken. With integers this should
raise a Floating Point Exception, but instead it is set to the address of some
variable in the backend.

---------------------------------------------
import std.stdio;
void main() {
    int a = 1;
    int b = 0;
    int c = a/b;
    writefln("%x", c);
}
---------------------------------------------
$ dmd x
$ ./x
Floating point exception
$ dmd -O x
$ ./x
9a9d34
---------------------------------------------

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

Reply via email to