mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Runtime] Stub out the same-conformance requirement check.
The compiler doesn't generate these yet, and we don't really have a good way to use or test them. For now, ignore them.
This commit is contained in:
@@ -776,15 +776,21 @@ bool swift::_checkGenericRequirements(
|
|||||||
_getTypeByMangledName(req.getMangledTypeName(), substGenericParam);
|
_getTypeByMangledName(req.getMangledTypeName(), substGenericParam);
|
||||||
if (!baseType) return true;
|
if (!baseType) return true;
|
||||||
|
|
||||||
|
// Check whether it's dynamically castable, which works as a superclass
|
||||||
|
// check.
|
||||||
if (!swift_dynamicCastMetatype(subjectType, baseType)) return true;
|
if (!swift_dynamicCastMetatype(subjectType, baseType)) return true;
|
||||||
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FIXME: Handle all of the other cases.
|
case GenericRequirementKind::SameConformance: {
|
||||||
default:
|
// FIXME: Implement this check.
|
||||||
return true;
|
continue;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Unknown generic requirement kind.
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Success!
|
// Success!
|
||||||
|
|||||||
Reference in New Issue
Block a user