[Issue 23905] Initialization of SumType with opaque enum causes ICE

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon May 8 13:27:21 UTC 2023


https://issues.dlang.org/show_bug.cgi?id=23905

--- Comment #1 from Paul Backus <snarwin+bugzilla at gmail.com> ---
Reduced:

---
struct SumType(T)
{
    T storage;

    bool opEquals(Rhs)(Rhs rhs)
    if (is(typeof(Rhs.init)))
    {
    }

}

enum Foo;

void main(){
    SumType!Foo data = Foo.init;
}
---

--


More information about the Digitalmars-d-bugs mailing list