``` pragma(msg, func!(int).mangleof); extern(C++, `bar`) { void func(T)(); } ``` SEGV with DMD64 D Compiler v2.084.0-170-g16cf015ec Moving `pragma` after the declaration, or using the non-string syntax does not.
@Geod24 created dlang/dmd pull request #10729 "Fix issue 19542: Forward reference segfault with string namespace C++ syntax" fixing this issue: - Fix issue 19542: Forward reference segfault with string namespace C++ syntax This segfaulted for some constructs, such as `pragma(msg)` and `enum`, but not others, such as `static assert`, hence why the value isn't checked. https://github.com/dlang/dmd/pull/10729
dlang/dmd pull request #10729 "Fix issue 19542: Forward reference segfault with string namespace C++ syntax" was merged into stable: - cc9f2d46deff94ea9e553d6b79c6206a3c6a8b6f by Geod24: Fix issue 19542: Forward reference segfault with string namespace C++ syntax This segfaulted for some constructs, such as `pragma(msg)` and `enum`, but not others, such as `static assert`, hence why the value isn't checked. https://github.com/dlang/dmd/pull/10729