internal bool ImplementsInterface(IReflect iface){
foreach (TypeExpression t in this.interfaces){
IReflect ir = t.ToIReflect();
if (ir == iface) return true;
if (ir is ClassScope && ((ClassScope)ir).ImplementsInterface(iface)) return true;
if (ir is Type && iface is Type && ((Type)iface).IsAssignableFrom((Type)ir)) return true;
}
return false;
}