← Back to index
|
Original Bugzilla link
Bug 713 – circular const definitions with module operator "." cause the compiler to segfault
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Linux
Creation time
2006-12-22T07:22:00Z
Last change time
2014-02-15T13:19:27Z
Keywords
ice-on-invalid-code
Assigned to
bugzilla
Creator
thomas-dloop
Comments
Comment #0
by thomas-dloop — 2006-12-22T07:22:24Z
(Originally posted by Wang Zhen <
[email protected]
> on 2006-02-17 as news:
[email protected]
) segfaults: # # const int a = .b; # const int b = a; # # # const int a = b; # const int b = .a; # doesn't segfault: # # const int a = .b; # const int b = .a; # # # const int a = b; # const int b = a; # test cases:
http://dstress.kuehne.cn/nocompile/c/const_32_A.d
http://dstress.kuehne.cn/nocompile/c/const_32_B.d
http://dstress.kuehne.cn/nocompile/c/const_32_C.d
http://dstress.kuehne.cn/nocompile/c/const_32_D.d
Comment #1
by clugdbug — 2009-04-02T15:03:41Z
On D1, this now generates a "Stack overflow". On D2, the equivalent code: enum int a = .b; enum int b = a; hangs.
Comment #2
by clugdbug — 2009-05-14T04:56:00Z
Fixed DMD2.030 and 1.045