Bug 1270 – -inline produces an ICE

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Windows
Creation time
2007-06-16T22:21:00Z
Last change time
2014-02-16T15:24:09Z
Keywords
ice-on-valid-code
Assigned to
bugzilla
Creator
tazz

Comments

Comment #0 by tazz — 2007-06-16T22:21:23Z
Normal compilation works, -O works, only -inline fails with "Internal error: ..\ztc\cod1.c 1662" The following code is a minimal but complete testcase: module bignum; struct bignum { bool smaller(bignum a, bignum b) { if (true) return true; else return false; // comment this out => no ICE for "dmd bignumtest.d -inline" assert(0); // comment this out => no ICE for "dmd bignumtest.d -inline" } bool equal(bignum a, bignum b) { if (!smaller(a,b)) // comment this out => no ICE for "dmd bignumtest.d -inline" return true; return false; } } void main() {}
Comment #1 by matti.niemenmaa+dbugzilla — 2007-06-17T03:12:34Z
Here's a slightly more minimal testcase: struct bignum { bool smaller() { if (true) return false; else return false; assert(0); } void equal() { if (!smaller) return; } }
Comment #2 by onlystupidspamhere — 2007-06-26T14:29:09Z
Fixed in 1.017.