[clang][Basic] Make SourceLocation usable as key in hash maps, NFCI
This change creates a `DenseMapInfo` trait specialization for the SourceLocation class. The empty key, the tombstone key, and the hash function are identical to `DenseMapInfo<unsigned>`, because we already have hash maps that use raw the representation of `SourceLocation` as a key. The update of existing `DenseMap`s containing raw representation of `SourceLocation`s will be done in a follow-up patch. As an example the patch makes use of the new trait in one instance: clang-tidy/google/UpgradeGoogletestCaseCheck.{h,cpp} Reviewed By: dexonsmith Differential Revision: https://reviews.llvm.org/D89719
Loading
Please sign in to comment