isCallable and templates
Steven Schveighoffer via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Fri Jun 10 10:32:03 PDT 2016
Consider:
import std.traits;
class Foo
{
void bar() {}
void baz()() {}
}
This works:
static assert(isCallable!(Foo.bar));
This does not:
static assert(isCallable!(Foo.baz));
However, clearly I can call baz due to IFTI (with the equivalent syntax,
someFoo.baz() or someFoo.baz). Is there a way to fix this?
-Steve
More information about the Digitalmars-d-learn
mailing list