version and extern problems
BCS
ao at pathlink.com
Sun Jul 8 15:26:05 PDT 2007
Reply to Russell,
> This sounds like the perfect place for alias, or something like it.
> The idea would be to write code like this:
>
> --------------
> version(Windows)
> <do alias declaration here>;
> else
> <do other alias delcaration here>;
> extern(myAlias) typedef void function() foo;
> --------------
> Problem is, I haven't yet found a syntax that I like. I came up with
> 3 possibilities:
>
> 1) alias extern(Windows) extern(myAlias);
>
how about alow extern to take a string?
const char[] type = "Windows";
extern(type);
More information about the Digitalmars-d
mailing list