``` extern(C++) struct A {} extern(C++,) struct A {} extern(C++, "") struct A {} extern(C++,mixin("")) struct A {} ``` should be all equivalent, currently only the first compiles. ``` extern(C++, true ? "ns" : "") struct B {} ``` compiles, but ``` extern(C++, false ? "ns" : "") struct B {} ``` does not.
@thewilsonator created dlang/dmd pull request #11905 "Fix issue 21340- extern(C++,) extern(C++, "") and extern(C++,mixin(""…" fixing this issue: - Fix issue 21340- extern(C++,) extern(C++, "") and extern(C++,mixin("")) should result in no namespace not an error https://github.com/dlang/dmd/pull/11905
that should be extern(C++,mixin("\"\"")) struct A {}
@thewilsonator created dlang/dlang.org pull request #2872 "document issue 21340 - extern(C++, (emptyTuple))" mentioning this issue: - document issue 21340 - extern(C++, (emptyTuple)) https://github.com/dlang/dlang.org/pull/2872
dlang/dmd pull request #11905 "Fix issue 21340 - extern(C++,(emptyTuple)) should result in no namespace not an error" was merged into master: - 17845af13059f8d03dc80af0fdcbcf639b877c13 by Nicholas Lindsay Wilson: Fix issue 21340 - extern(C++,(emptyTuple)) should result in no namespace not an error https://github.com/dlang/dmd/pull/11905
dlang/dlang.org pull request #2872 "Document issue 21340 - `extern(C++, (expression))` now accepts empty tuples" was merged into master: - 4f3b1fad4532e2513c5ef74ed288419933b27ab7 by Nicholas Lindsay Wilson: document issue 21340 - extern(C++, (emptyTuple)) https://github.com/dlang/dlang.org/pull/2872