[Issue 15450] ICE during CTFE of legit function
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Tue Dec 15 15:01:37 PST 2015
https://issues.dlang.org/show_bug.cgi?id=15450
--- Comment #1 from Andrei Alexandrescu <andrei at erdani.com> ---
Shorter repro. It's the labeled continue that's the problem:
struct BigO
{
struct Atom
{
int id;
double exp;
double logExp;
}
private Atom[][] terms;
int opCmp(const BigO rhs) const
{
int result = 0;
bigone:
foreach (ref l; terms)
{
foreach (ref r; rhs.terms)
{
continue bigone;
}
}
return result;
}
}
static immutable
linear = BigO([ [ BigO.Atom(0, 1, 0) ] ]);
static assert(linear >= linear);
--
More information about the Digitalmars-d-bugs
mailing list