diff options
author | Volodymyr Sapsai <vsapsai@apple.com> | 2022-12-05 18:03:08 -0800 |
---|---|---|
committer | Volodymyr Sapsai <vsapsai@apple.com> | 2023-01-19 15:58:31 -0600 |
commit | f33b5b1bf703ee5ff73126fefe2a9bcbd54db457 (patch) | |
tree | 9ba203ba9147b0fe2e00db93e9a42af080c8df61 /clang/lib/Frontend/CompilerInvocation.cpp | |
parent | 160bc160b9b114069a8cb9b4cc887aa86e5ca7c4 (diff) | |
download | llvm-f33b5b1bf703ee5ff73126fefe2a9bcbd54db457.zip llvm-f33b5b1bf703ee5ff73126fefe2a9bcbd54db457.tar.gz llvm-f33b5b1bf703ee5ff73126fefe2a9bcbd54db457.tar.bz2 |
[ODRHash] Detect mismatches in anonymous `RecordDecl`.
Allow completing a redeclaration check for anonymous structs/unions
inside `RecordDecl`, so we deserialize and compare anonymous entities
from different modules.
Completing the redeclaration chain for `RecordDecl` in
`ASTContext::getASTRecordLayout` mimics the behavior in
`CXXRecordDecl::dataPtr`. Instead of completing the redeclaration chain
every time we request a definition, do that right before we need a
complete definition in `ASTContext::getASTRecordLayout`.
Such code is required only for anonymous `RecordDecl` because we
deserialize named decls when we look them up by name. But it doesn't
work for anonymous decls as they don't have a name. That's why need to
force deserialization of anonymous decls in a different way.
rdar://81864186
Differential Revision: https://reviews.llvm.org/D140055
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions