← Back to index
|
Original Bugzilla link
Bug 530 – segfault assigning array literal to a non-array const
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Windows
Creation time
2006-11-16T08:19:00Z
Last change time
2014-02-15T13:20:13Z
Keywords
ice-on-invalid-code
Assigned to
bugzilla
Creator
clugdbug
Comments
Comment #0
by clugdbug — 2006-11-16T08:19:07Z
They don't get much shorter than this. -------- const int a = [1,2]; -------- Also crashes with: -------- const int a = [];
Comment #1
by bruno.do.medeiros+deebugz — 2006-11-18T08:14:31Z
I tried those two cases, on Windows, DMD .174, and I get no crash. The compiler exits with: main.d(1): Error: cannot use array to initialize
Comment #2
by matti.niemenmaa+dbugzilla — 2006-12-03T03:38:33Z
Fixed in DMD 0.176.
Comment #3
by thomas-dloop — 2006-12-30T20:10:09Z
Added to DStress as
http://dstress.kuehne.cn/nocompile/a/array_initialization_31_A.d
http://dstress.kuehne.cn/nocompile/a/array_initialization_31_B.d
http://dstress.kuehne.cn/nocompile/a/array_initialization_31_C.d
http://dstress.kuehne.cn/nocompile/a/array_initialization_31_D.d
http://dstress.kuehne.cn/nocompile/a/array_initialization_31_E.d
http://dstress.kuehne.cn/nocompile/a/array_initialization_31_F.d