Skip to content

Commit 846617f

Browse files
authored
Merge pull request #10907 from CodaFi/mangolia
2 parents ec77bd0 + 36a07e9 commit 846617f

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

stdlib/public/runtime/Reflection.mm

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1210,9 +1210,8 @@ static Mirror ObjC_getMirrorForSuperclass(Class sup,
12101210

12111211
// Check if we are dealing with Swift mangled name, otherwise, don't try
12121212
// to demangle and send indication to the user.
1213-
if (mangledName[0] != '_' || mangledName[1] != 'T') {
1214-
return nullptr;
1215-
}
1213+
if (!Demangle::isSwiftSymbol(mangledName))
1214+
return nullptr; // Not a mangled name
12161215

12171216
// Demangle the name.
12181217
auto options = Demangle::DemangleOptions();

0 commit comments

Comments
 (0)