class Foo
{
static void foo(this T)()
{
pragma(msg, T.stringof);
}
}
class Bar : Foo {}
Foo.foo(); // prints "Foo"
Bar.foo(); // prints "Bar"
For some reason this feature was removed, it might be that it was never
indented to work for static methods.
Can we make it work again for static methods? It would be really handy for creating Objective-C bindings.
-- /Jacob Carlborg
