Bug 8710 – std.typecons.Tuple and double declared nested struct crashes dmd

Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2012-09-23T05:37:00Z
Last change time
2013-05-06T11:41:38Z
Keywords
ice
Assigned to
nobody
Creator
k.hara.pg

Comments

Comment #0 by k.hara.pg — 2012-09-23T05:37:41Z
Test case: ---- import std.typecons; void main() { { struct S {} } { struct S { bool opEquals(T)(T a) { return false; } } auto t1 = tuple(S.init); // crash dmd } } ---- Reduced test case doesn't crash dmd, but cause an ICE. struct Tuple(T...) { T field; } void main() { { struct S {} } { struct S { bool opEquals(T)(T a) { return false; } } auto t2 = Tuple!(S)(S.init); // ICE // assert struct.c(227) alignment > 0 && !(alignment & (alignment - 1)) } }
Comment #1 by maxim — 2013-05-06T11:41:38Z
*** This issue has been marked as a duplicate of issue 8612 ***