extern(Windows) alias bug

John C johnch_atms at hotmail.com
Mon May 29 14:50:23 PDT 2006


The following are not equivalent, though I can't understand why not.

template TFunc1() {
   extern(Windows) alias int function(int) TFunc1;
}

alias int function(int) funcA;
template TFunc2() {
   extern(Windows) alias funcA TFunc2;
}

void main() {
   writefln(TFunc1!().mangleof); // PWiZi
   writefln(TFunc2!().mangleof); // PFiZi
}

So the extern(Windows) gets applied to TFunc1, but not TFunc2.



More information about the Digitalmars-d-bugs mailing list