Bug 1145 – bad codegen with ulong+float

Status
RESOLVED
Resolution
FIXED
Severity
major
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2007-04-14T14:19:00Z
Last change time
2015-06-09T05:14:40Z
Keywords
wrong-code
Assigned to
ibuclaw
Creator
casantander1

Comments

Comment #0 by casantander1 — 2007-04-14T14:19:54Z
This doesn't pass the assert: //------- ulong foo () { return cast(ulong) (cast(ulong) 1176576512 + cast(float) -2); } void main () { assert(foo()==1176576510); } //-------
Comment #1 by thomas-dloop — 2007-04-23T12:55:07Z
Comment #2 by ibuclaw — 2010-08-05T14:28:02Z
Fixed in hg commit 119 / release 0.25