Request: is(typeof(X.init) == X) for all X
Oskar Linde
oskar.lindeREM at OVEgmail.com
Fri May 5 09:45:32 PDT 2006
Hi,
The subject says it all. This is currently not true for static arrays:
template test(X) {
static assert(is(typeof(X.init) == X));
}
struct T{}
mixin test!(int);
mixin test!(int *);
mixin test!(void delegate());
mixin test!(void function());
mixin test!(Object);
mixin test!(T);
mixin test!(T*);
mixin test!(char[]);
mixin test!(char[5]);
Gives:
init.d(2): static assert (is(char == char[5])) is false
/Oskar
More information about the Digitalmars-d
mailing list