[Issue 13235] New: ICE on mutually recursive tuple type
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Fri Aug 1 05:24:25 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=13235
Issue ID: 13235
Summary: ICE on mutually recursive tuple type
Product: D
Version: D2
Hardware: x86_64
OS: Linux
Status: NEW
Keywords: ice-on-valid-code, wrong-code
Severity: regression
Priority: P1
Component: DMD
Assignee: nobody at puremagic.com
Reporter: timon.gehr at gmx.ch
DMD 2.066.0-rc1
struct Tuple(T...){
pragma(msg, T); // shown twice!
T expand;
alias expand field;
this(T values){
field = values;
}
}
struct Foo{ Tuple!(int,Foo)* foo; }
static bar(T...)(T args){ }
void main(){
assert(Tuple!(int,Foo)(1,Foo()).expand[0] == 1);
}
The code should compile and run. This issue affects Phobos.
The assertion fails with DMD 2.060, so the bug is not new, just the ICE.
(So maybe this is not a regression, but it is hard to tell.)
--
More information about the Digitalmars-d-bugs
mailing list