Skip to content

Commit 3061530

Browse files
committed
Swift: Mangle AssociatedTypeDecl.
1 parent b807d00 commit 3061530

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

swift/extractor/mangler/SwiftMangler.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,10 @@ SwiftMangledName SwiftMangler::visitGenericTypeParamDecl(const swift::GenericTyp
141141
return visitValueDecl(decl, /*force=*/true) << '_' << decl->getDepth() << '_' << decl->getIndex();
142142
}
143143

144+
SwiftMangledName SwiftMangler::visitAssociatedTypeDecl(const swift::AssociatedTypeDecl* decl) {
145+
return visitValueDecl(decl, /*force=*/true);
146+
}
147+
144148
SwiftMangledName SwiftMangler::visitModuleType(const swift::ModuleType* type) {
145149
return initMangled(type) << fetch(type->getModule());
146150
}

swift/extractor/mangler/SwiftMangler.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ class SwiftMangler : private swift::TypeVisitor<SwiftMangler, SwiftMangledName>,
6262
SwiftMangledName visitSubscriptDecl(const swift::SubscriptDecl* decl);
6363
SwiftMangledName visitVarDecl(const swift::VarDecl* decl);
6464
SwiftMangledName visitGenericTypeParamDecl(const swift::GenericTypeParamDecl* decl);
65+
SwiftMangledName visitAssociatedTypeDecl(const swift::AssociatedTypeDecl* decl);
6566

6667
// default fallback for non mangled types. This covers types that should not appear in normal
6768
// successful extractor runs, like ErrorType

0 commit comments

Comments
 (0)