Bug 9411 – Assigning to delegate, assertion failure on line 1702 in file 'cast.c'
Status
RESOLVED
Resolution
WORKSFORME
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-01-27T19:12:00Z
Last change time
2013-06-24T22:02:22Z
Assigned to
nobody
Creator
callumenator
Comments
Comment #0 by callumenator — 2013-01-27T19:12:38Z
Compiling with 2.061 release.
void main()
{
int z;
typeof((int a){return z;}) dg;
dg = cast(typeof((int a){return z;})) (int a){return z;};
}
Assertion failure: 'e->type->nextOf()->covariant(t->nextOf()) == 1' on line 1702 in file 'cast.c'
If dg is made a function by removing reference to z, it compiles.