Bug 2566 – Regression:compiler ICE from TypeTuple

Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
x86
OS
Linux
Creation time
2009-01-07T15:35:00Z
Last change time
2014-03-01T00:36:32Z
Keywords
ice-on-invalid-code
Assigned to
bugzilla
Creator
site.puremagic.com

Comments

Comment #0 by site.puremagic.com — 2009-01-07T15:35:01Z
// dmd 1.038 & 1.039 segfault on this code: import std.typetuple; class Foo(T, U) { int bar(T t, U u) { } } void foo(TP ...)() { auto f = new Foo!(TP); } void main() { foo!(TypeTuple!(int,float))(); } // dmd 1.037 properly reports an error: test.d(6): function test.Foo!(int,float).Foo.bar expected to return a value of type int test.d(10): template instance test.Foo!(int,float) error instantiating test.d(14): template instance test.foo!(int,float) error instantiating
Comment #1 by clugdbug — 2009-04-03T06:42:14Z
No longer segfaults in DMD 1.042, now it's an ICE with Assertion failure: 'i < parameters->dim' on line 806 in file 'template.c' abnormal program termination In DMD2.027, it produces: fog.d(7): Error: template fog.foo(TP...) declaration TP is already defined which doesn't seem correct.
Comment #2 by clugdbug — 2009-04-03T07:06:52Z
Changing severity, since it never actually compiled.
Comment #3 by clugdbug — 2009-04-03T07:11:56Z
Actually it's a duplicate! *** This bug has been marked as a duplicate of 2229 ***