Ideally, the alias part of the grammar could be extended and isSomething simplified as: alias isSomething(T) = __traits(compiles, { Unrelated* up; T.init.doSomething(up); } ); But this is not accepted by the grammar right now, because of __traits()