[clang] [Modules] Delay deserialization of preferred_name attribute at r… (PR #122726)
Chuanqi Xu via cfe-commits
cfe-commits at lists.llvm.org
Tue Jan 14 23:43:18 PST 2025
================
@@ -1205,6 +1205,23 @@ class ASTReader
/// been completed.
std::deque<PendingDeclContextInfo> PendingDeclContextInfos;
+ /// Deserialization of some attributes must be deferred since they refer
+ /// to themselves in their type (e.g., preferred_name attribute refers to the
+ /// typedef that refers back to the template specialization of the template
+ /// that the attribute is attached to).
+ /// More attributes that store TypeSourceInfo might be potentially affected,
+ /// see https://github.com/llvm/llvm-project/issues/56490 for details.
+ struct DeferredAttribute {
+ uint64_t RecordIdx;
----------------
ChuanqiXu9 wrote:
nit: Add a comment to the field. e.g., something like the Index of the delayed attribute in the Record of the targeted decl.
https://github.com/llvm/llvm-project/pull/122726
More information about the cfe-commits
mailing list