Bug 2555 – ICE using invalid tuple property in a declaration
Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Windows
Creation time
2009-01-05T02:41:00Z
Last change time
2014-03-01T00:36:29Z
Keywords
ice-on-invalid-code
Assigned to
bugzilla
Creator
clugdbug
Comments
Comment #0 by clugdbug — 2009-01-05T02:41:46Z
-----
int foo(T...)(char [T.sizeof] x)
{
return 0;
}
int c = foo!(int, int)("yy");
-----
It also segfaults if the declaration is in a function, so it's not a CTFE issue.
It segfaults if any invalid property is used.
----
int foo(T...)(char [T.z] x) { return 0; }
void main() { int c = foo!(int, int)("yy"); }
Comment #1 by clugdbug — 2009-04-02T14:59:46Z
No longer segfaults. Gives correct error messages on DMD2.027, while on DMD1.042 it ICEs:
Assertion failure: 'i < parameters->dim' on line 806 in file 'template.c'
Comment #2 by clugdbug — 2009-04-03T08:13:23Z
*** This bug has been marked as a duplicate of 2229 ***