runtime: rename _TMps8Hashable to HashableProtocolDescriptor

This commit is contained in:
Dmitri Gribenko
2016-08-12 00:36:36 -07:00
parent 89d0d62bd6
commit dfb4f56e55
7 changed files with 49 additions and 49 deletions

View File

@@ -892,9 +892,6 @@ extern "C" id swift_stdlib_getErrorEmbeddedNSErrorIndirect(
/// Nominal type descriptor for Swift.AnyHashable.
extern "C" const NominalTypeDescriptor _TMnVs11AnyHashable;
/// Protocol descriptor for Swift.Hashable.
extern "C" const ProtocolDescriptor _TMps8Hashable;
static bool isAnyHashableType(const StructMetadata *type) {
return type->getDescription() == &_TMnVs11AnyHashable;
}
@@ -914,7 +911,7 @@ static bool _dynamicCastToAnyHashable(OpaqueValue *destination,
DynamicCastFlags flags) {
// Look for a conformance to Hashable.
auto hashableConformance = reinterpret_cast<const HashableWitnessTable *>(
swift_conformsToProtocol(sourceType, &_TMps8Hashable));
swift_conformsToProtocol(sourceType, &HashableProtocolDescriptor));
// If we don't find one, the cast fails.
if (!hashableConformance) {