and while I'm at it I need to conditionally constrain types. interface A(T) where(!isBasicType!T, (T : B)); which is suppose to require T to inherit from B if T is not basic type.