aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Lex/ModuleMap.cpp
diff options
context:
space:
mode:
authorHubert Tong <hubert.reinterpretcast@gmail.com>2022-03-24 20:11:54 -0400
committerHubert Tong <hubert.reinterpretcast@gmail.com>2022-03-24 20:17:49 -0400
commitce21c926f8efe969717e21e3ae6c5a3246b3d455 (patch)
tree6e4443f64e1b127c4c6bb93f27b2a50739348275 /clang/lib/Lex/ModuleMap.cpp
parentfcbe64ddb8f915c240ee00e7984d8ca18b1ad424 (diff)
downloadllvm-ce21c926f8efe969717e21e3ae6c5a3246b3d455.zip
llvm-ce21c926f8efe969717e21e3ae6c5a3246b3d455.tar.gz
llvm-ce21c926f8efe969717e21e3ae6c5a3246b3d455.tar.bz2
[Clang] Work with multiple pragmas weak before definition
Update `WeakUndeclaredIdentifiers` to hold a collection of weak aliases per identifier instead of only one. This also allows the "used" state to be removed from `WeakInfo` because it is really only there as an alternative to removing processed map entries, and we can represent that using an empty set now. The serialization code is updated for the removal of the field. Additionally, a PCH test is added for the new functionality. The records are grouped by the "target" identifier, which was already being used as a key for lookup purposes. We also store only one record per alias name; combined, this means that diagnostics are grouped by the "target" and limited to one per alias (which should be acceptable). Fixes PR28611. Fixes llvm/llvm-project#28985. Reviewed By: aaron.ballman, cebowleratibm Differential Revision: https://reviews.llvm.org/D121927 Co-authored-by: Rachel Craik <rcraik@ca.ibm.com> Co-authored-by: Jamie Schmeiser <schmeise@ca.ibm.com>
Diffstat (limited to 'clang/lib/Lex/ModuleMap.cpp')
0 files changed, 0 insertions, 0 deletions