The following code reproduces the wrong linkage result. --- // https://wandbox.org/permlink/0kSYkUvi82gW9kRR extern (C) struct T {} void main() { assert(__traits(getLinkage, T) == "D"); // should be C }
Sorry I misunderstood.