Skip to content

Commit 1674f86

Browse files
authored
Merge pull request #59891 from rjmccall/ext-exi-pac-fix-5.7
[5.7] Fix extended existential symbolic demangling on arm64e
2 parents f1c35d5 + 310e0f4 commit 1674f86

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

stdlib/public/runtime/MetadataLookup.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,10 +162,20 @@ ResolveAsSymbolicReference::operator()(SymbolicReferenceKind kind,
162162
case Demangle::SymbolicReferenceKind::UniqueExtendedExistentialTypeShape:
163163
nodeKind = Node::Kind::UniqueExtendedExistentialTypeShapeSymbolicReference;
164164
isType = false;
165+
#if SWIFT_PTRAUTH
166+
ptr = (uintptr_t)ptrauth_sign_unauthenticated((void*)ptr,
167+
ptrauth_key_process_independent_data,
168+
SpecialPointerAuthDiscriminators::ExtendedExistentialTypeShape);
169+
#endif
165170
break;
166171
case Demangle::SymbolicReferenceKind::NonUniqueExtendedExistentialTypeShape:
167172
nodeKind = Node::Kind::NonUniqueExtendedExistentialTypeShapeSymbolicReference;
168173
isType = false;
174+
#if SWIFT_PTRAUTH
175+
ptr = (uintptr_t)ptrauth_sign_unauthenticated((void*)ptr,
176+
ptrauth_key_process_independent_data,
177+
SpecialPointerAuthDiscriminators::NonUniqueExtendedExistentialTypeShape);
178+
#endif
169179
break;
170180
}
171181

0 commit comments

Comments
 (0)