File tree Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -124,12 +124,18 @@ class Mangler {
124
124
void appendIdentifier (StringRef ident);
125
125
126
126
void addSubstitution (const void *ptr) {
127
- if (UseSubstitutions)
128
- Substitutions[ptr] = Substitutions.size () + StringSubstitutions.size ();
127
+ if (!UseSubstitutions)
128
+ return ;
129
+
130
+ auto value = Substitutions.size () + StringSubstitutions.size ();
131
+ Substitutions[ptr] = value;
129
132
}
130
133
void addSubstitution (StringRef Str) {
131
- if (UseSubstitutions)
132
- StringSubstitutions[Str] = Substitutions.size () + StringSubstitutions.size ();
134
+ if (!UseSubstitutions)
135
+ return ;
136
+
137
+ auto value = Substitutions.size () + StringSubstitutions.size ();
138
+ StringSubstitutions[Str] = value;
133
139
}
134
140
135
141
bool tryMangleSubstitution (const void *ptr);
You can’t perform that action at this time.
0 commit comments