diff options
author | Vlad Serebrennikov <serebrennikov.vladislav@gmail.com> | 2023-11-02 20:57:29 +0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-02 20:57:29 +0400 |
commit | 8775947633bf189e1847707932b1015f04640ea0 (patch) | |
tree | 44e121ebf486cda5de36737d228ed9380d160d7c /llvm/lib/IR/Module.cpp | |
parent | 8a3e4b5f32e6d333b6fa70aa6c505046ce18630f (diff) | |
download | llvm-8775947633bf189e1847707932b1015f04640ea0.zip llvm-8775947633bf189e1847707932b1015f04640ea0.tar.gz llvm-8775947633bf189e1847707932b1015f04640ea0.tar.bz2 |
[clang][NFC] Refactor `clang::Linkage` (#71049)
This patch introduces a new enumerator `Invalid = 0`, shifting other enumerators by +1. Contrary to how it might sound, this actually affirms status quo of how this enum is stored in `clang::Decl`:
```
/// If 0, we have not computed the linkage of this declaration.
/// Otherwise, it is the linkage + 1.
mutable unsigned CacheValidAndLinkage : 3;
```
This patch makes debuggers to not be mistaken about enumerator stored in this bit-field. It also converts `clang::Linkage` to a scoped enum.
Diffstat (limited to 'llvm/lib/IR/Module.cpp')
0 files changed, 0 insertions, 0 deletions