Skip to content

Commit 5a02233

Browse files
author
git apple-llvm automerger
committed
Merge commit '85c78e85b83f' from swift/release/5.5 into swift/main
2 parents 370a5cf + 85c78e8 commit 5a02233

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

lldb/source/Plugins/LanguageRuntime/Swift/SwiftLanguageRuntimeNames.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -682,6 +682,7 @@ SwiftLanguageRuntime::DemangleSymbolAsString(StringRef symbol, DemangleMode mode
682682
options.QualifyEntities = true;
683683
options.DisplayModuleNames = true;
684684
options.DisplayLocalNameContexts = false;
685+
options.DisplayDebuggerGeneratedModule = false;
685686
break;
686687
}
687688

lldb/source/Plugins/TypeSystem/Swift/TypeSystemSwiftTypeRef.cpp

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3168,6 +3168,15 @@ bool TypeSystemSwiftTypeRef::IsTypedefType(opaque_compiler_type_t type) {
31683168
NodePointer node = GetDemangledType(dem, AsMangledName(type));
31693169
if (node && node->getKind() == Node::Kind::BuiltinTypeName)
31703170
return impl();
3171+
3172+
// This is a discrepancy with `SwiftASTContext`. `impl` correctly
3173+
// returns true, but `VALIDATE_AND_RETURN` will assert. This hardcoded
3174+
// handling of `__C.NSNotificationName` and `__C.NSDecimal` can be removed
3175+
// when the `VALIDATE_AND_RETURN` is removed.
3176+
auto mangled_name = GetMangledTypeName(type);
3177+
if (mangled_name == "$sSo18NSNotificationNameaD" ||
3178+
mangled_name == "$sSo9NSDecimalaD")
3179+
return impl();
31713180
#endif
31723181
VALIDATE_AND_RETURN(impl, IsTypedefType, type, (ReconstructType(type)),
31733182
(ReconstructType(type)));
@@ -3200,6 +3209,15 @@ TypeSystemSwiftTypeRef::GetTypedefedType(opaque_compiler_type_t type) {
32003209
NodePointer node = GetDemangledType(dem, AsMangledName(type));
32013210
if (node && node->getKind() == Node::Kind::BuiltinTypeName)
32023211
return impl();
3212+
3213+
// This is a discrepancy with `SwiftASTContext`. `impl` correctly
3214+
// returns true, but `VALIDATE_AND_RETURN` will assert. This hardcoded
3215+
// handling of `__C.NSNotificationName` and `__C.NSDecimal` can be removed
3216+
// when the `VALIDATE_AND_RETURN` is removed.
3217+
auto mangled_name = GetMangledTypeName(type);
3218+
if (mangled_name == "$sSo18NSNotificationNameaD" ||
3219+
mangled_name == "$sSo9NSDecimalaD")
3220+
return impl();
32033221
#endif
32043222
VALIDATE_AND_RETURN(impl, GetTypedefedType, type, (ReconstructType(type)),
32053223
(ReconstructType(type)));

0 commit comments

Comments
 (0)