DMD: can't get extern __gshared to work right (vs. LDC)

DanielG simpletangent at
Mon Feb 18 17:26:07 UTC 2019

In the meantime, while I'm waiting for this bug to be noticed by 
anybody with the skills to address it, what would be the most 
elegant way of working around it?

Obviously I could do a:

version(Windows) {
   export extern __gshared ...
} else {
   extern __gshared ...

But what's the minimal way of toggling the presence of "export" 
in a declaration? Using mixins feels kind of gross for this, but 
if that's the only option ...

Almost makes me long for the C preprocessor :P

More information about the Digitalmars-d-learn mailing list