[clang] [Clang][Sema] Refactor collection of multi-level template argument lists (PR #106585)
Krystian Stasiowski via cfe-commits
cfe-commits at lists.llvm.org
Fri Aug 30 06:08:59 PDT 2024
================
@@ -809,8 +809,9 @@ class RedeclarableTemplateDecl : public TemplateDecl,
};
/// Pointer to the common data shared by all declarations of this
- /// template.
- mutable CommonBase *Common = nullptr;
+ /// template, and a flag indicating if the template is a member
+ /// specialization.
+ mutable llvm::PointerIntPair<CommonBase *, 1, bool> Common;
----------------
sdkrystian wrote:
> Do you think it is more appropriate to move the flag to `Common->InstantiatedFromMember`? That way the flag won't be scattered, right?
I moved the flag here because we want to set the flag before we know whether it is a redeclaration.
https://github.com/llvm/llvm-project/pull/106585
More information about the cfe-commits
mailing list