D - about static constructor in template
static constructor in other module's template never called.
is it a bug or not?
--- other_module.d
template template_test(T) {
static this() { printf("static constructor\n"); }
class foo { static this() { printf("foo's static constructor\n"); } }
static foo t;
}
--- test.d
import other_module;
class foo {}
int main(){
instance template_test(foo) f;
while(1) {}
return 0;
}
/**
compiled with
dcd test.d other_module.d
in windows
*/
Dec 02 2003
"yaneurao" <yaneurao_member pathlink.com> wrote in message news:bqingn$2m7o$1 digitaldaemon.com...static constructor in other module's template never called. is it a bug or not?Bug.
Dec 19 2003








"Walter" <walter digitalmars.com>