================
@@ -758,6 +761,10 @@ class APINotesReader::Implementation {
/// The identifier table.
std::unique_ptr<SerializedIdentifierTable> IdentifierTable;
+ /// Lazy reverse lookup cache from identifier ID to string.
+ bool IdentifierStringsInitialized = false;
+ llvm::DenseMap<uint32_t, llvm::StringRef> IdentifierStrings;
----------------
j-hui wrote:
If the flag is just guarding the initialization of `IdentifierStrings`, how
about just putting it in an optional, i.e.,
```suggestion
std::optional<llvm::DenseMap<uint32_t, llvm::StringRef>> IdentifierStrings;
```
https://github.com/llvm/llvm-project/pull/209408
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits