Skip to content

Commit 249c73a

Browse files
committed
feat: ASTVisitor extracts the full introduced name
1 parent 67fe17e commit 249c73a

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/lib/AST/ASTVisitor.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1218,22 +1218,23 @@ populate(
12181218
I.AliasedSymbol = toNameInfo(Aliased, {}, NNS);
12191219
}
12201220

1221-
12221221
void
12231222
ASTVisitor::
12241223
populate(
12251224
UsingInfo& I,
12261225
UsingDecl const* D)
12271226
{
12281227
I.Class = UsingClass::Normal;
1229-
I.Qualifier = toNameInfo(D->getQualifier());
1228+
DeclarationName const& Name = D->getNameInfo().getName();
1229+
NestedNameSpecifier const& NNS = D->getQualifier();
1230+
I.IntroducedName = toNameInfo(Name, {}, NNS);
12301231
for (UsingShadowDecl const* UDS: D->shadows())
12311232
{
12321233
ScopeExitRestore s(mode_, Dependency);
12331234
Decl* S = UDS->getTargetDecl();
12341235
if (Info* SI = findOrTraverse(S))
12351236
{
1236-
I.UsingSymbols.emplace_back(SI->id);
1237+
I.ShadowDeclarations.emplace_back(SI->id);
12371238
}
12381239
}
12391240
}

0 commit comments

Comments
 (0)