August 17, 2023 [Issue 24089] New: Error: Unknown for bad ordering of struct/function instantiation with sema error | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24089 Issue ID: 24089 Summary: Error: Unknown for bad ordering of struct/function instantiation with sema error Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nobody@puremagic.com Reporter: default_357-line@yahoo.de Given this code: ``` void fun() { enum e = __traits(compiles, templateFun()); Foo!() a; a.bar.baz(); } struct Foo() { Bar!() bar; } void templateFun()() { Foo!(); } struct Bar() { void baz()() { } void erroring() { BREAK_SEMA; } } ``` DMD says "Error: unknown, please file report on issues.dlang.org". Somehow the particular ordering of __traits(compiles) swallows the "undefined identifier BREAK_SEMA" error with no sign. -- |
Copyright © 1999-2021 by the D Language Foundation