[Issue 17407] New: [REG] __traits(compiles) triggers assertion failure
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Thu May 18 05:20:32 PDT 2017
https://issues.dlang.org/show_bug.cgi?id=17407
Issue ID: 17407
Summary: [REG] __traits(compiles) triggers assertion failure
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: regression
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: mathias.lang at sociomantic.com
```
bool foo ()
{
void delegate ( ) longest_convert;
return __traits(compiles, longest_convert = &doesNotExists);
}
static assert(!foo);
```
This code result in an assertion failure with DMD v2.075.0-devel-f234dde37
(master) and probably earlier.
The assertion in question is
https://github.com/dlang/dmd/blob/f234dde373acc2d6b4c32656c13edba764a925a5/src/ddmd/dinterpret.d#L7125
It only shows up with a debug build of DMD, as release builds don't have
`assert` on.
--
More information about the Digitalmars-d-bugs
mailing list