Bug 6302 – Function imports in debug blocks crashes compiler

Status
RESOLVED
Resolution
FIXED
Severity
critical
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
Other
OS
Windows
Creation time
2011-07-12T17:12:00Z
Last change time
2012-01-04T07:10:47Z
Assigned to
nobody
Creator
andrej.mitrovich

Comments

Comment #0 by andrej.mitrovich — 2011-07-12T17:12:17Z
module dmd_crash; void main() { debug { import std.math; FloatingPointControl fpc; fpc.enableExceptions(FloatingPointControl.severeExceptions); } } > dmd -debug dmd_crash.d --------------------------- dmd.exe - Application Error --------------------------- The instruction at "0x00406be3" referenced memory at "0x00000030". The memory could not be "read". Click on OK to terminate the program Click on CANCEL to debug the program --------------------------- OK Cancel ---------------------------
Comment #1 by andrej.mitrovich — 2011-07-12T17:45:41Z
Lowering to critical as I can use my own version statements to work around this: void main() { version (Debug) { import std.math; FloatingPointControl fpc; fpc.enableExceptions(FloatingPointControl.severeExceptions); } } > dmd -version=Debug dmd_crash.d This will work.
Comment #2 by andrej.mitrovich — 2012-01-04T07:10:47Z
Fixed in 2.057, but again there's no reference to a pull request. :/