[PATCH] D141280: [clang][wip] Build UsingType for elaborated type specifiers.
Haojian Wu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jan 10 00:13:38 PST 2023
hokein added a comment.
though this is a hack implementation, the result seems promising to me, so I post it for initial thoughts.
================
Comment at: clang/include/clang/Sema/Sema.h:3307
Decl *ActOnTag(Scope *S, unsigned TagSpec, TagUseKind TUK,
SourceLocation KWLoc, CXXScopeSpec &SS, IdentifierInfo *Name,
----------------
This is the key place where it returns the underlying decl.
Alternatively, we could return the UsingDecl as the result (there are only 4 places using it, might be possible to check/verify/adjust all caller place, I feel a bit scary about it, as the name indicates, caller might assume the return Decl is a `TagDecl`, e.g. the [case](https://github.com/llvm/llvm-project/blob/main/clang/lib/Sema/SemaTemplate.cpp#L10195))
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D141280/new/
https://reviews.llvm.org/D141280
More information about the cfe-commits
mailing list