@@ -65,17 +65,16 @@ SwiftMangledName SwiftMangler::visitValueDecl(const swift::ValueDecl* decl, bool
65
65
auto ret = initMangled (decl);
66
66
std::string name;
67
67
llvm::raw_string_ostream oss{name};
68
- oss << decl->getName ();
68
+ decl->getName (). print (oss );
69
69
ret << name;
70
70
if (decl->isStatic ()) {
71
71
ret << " |static" ;
72
72
}
73
73
return ret;
74
74
}
75
75
76
- SwiftMangledName SwiftMangler::visitTypeDiscriminatedValueDecl (const swift::ValueDecl* decl,
77
- bool force) {
78
- if (auto ret = visitValueDecl (decl, force)) {
76
+ SwiftMangledName SwiftMangler::visitTypeDiscriminatedValueDecl (const swift::ValueDecl* decl) {
77
+ if (auto ret = visitValueDecl (decl)) {
79
78
ret << fetch (decl->getInterfaceType ()->getCanonicalType ());
80
79
return ret;
81
80
}
@@ -86,13 +85,6 @@ SwiftMangledName SwiftMangler::visitAbstractFunctionDecl(const swift::AbstractFu
86
85
return visitTypeDiscriminatedValueDecl (decl);
87
86
}
88
87
89
- SwiftMangledName SwiftMangler::visitAccessorDecl (const swift::AccessorDecl* decl) {
90
- std::string name;
91
- llvm::raw_string_ostream oss{name};
92
- decl->printUserFacingName (oss);
93
- return visitTypeDiscriminatedValueDecl (decl, /* force=*/ true ) << ' _' << name;
94
- }
95
-
96
88
SwiftMangledName SwiftMangler::visitSubscriptDecl (const swift::SubscriptDecl* decl) {
97
89
return visitTypeDiscriminatedValueDecl (decl);
98
90
}
@@ -101,10 +93,6 @@ SwiftMangledName SwiftMangler::visitVarDecl(const swift::VarDecl* decl) {
101
93
return visitTypeDiscriminatedValueDecl (decl);
102
94
}
103
95
104
- SwiftMangledName SwiftMangler::visitParamDecl (const swift::ParamDecl* decl) {
105
- return visitTypeDiscriminatedValueDecl (decl, /* force=*/ true );
106
- }
107
-
108
96
SwiftMangledName SwiftMangler::visitExtensionDecl (const swift::ExtensionDecl* decl) {
109
97
if (decl->getDeclContext ()->isLocalContext ()) {
110
98
return {};
0 commit comments