[PATCH] D128690: [ODRHash diagnostics] Preparation to minimize subsequent diffs. NFC.
Chuanqi Xu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Jul 10 19:21:52 PDT 2022
ChuanqiXu accepted this revision.
ChuanqiXu added a comment.
This revision is now accepted and ready to land.
LGTM basically.
================
Comment at: clang/lib/Serialization/ASTReader.cpp:10621-10626
// Compute the hash of the method as if it has no body.
- auto ComputeCXXMethodODRHash = [&Hash](const CXXMethodDecl *D) {
- Hash.clear();
- Hash.AddFunctionDecl(D, true /*SkipBody*/);
- return Hash.CalculateHash();
+ auto ComputeCXXMethodODRHash = [](const CXXMethodDecl *D) {
+ ODRHash Hasher;
+ Hasher.AddFunctionDecl(D, true /*SkipBody*/);
+ return Hasher.CalculateHash();
};
----------------
Couldn't we hoist this like others?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D128690/new/
https://reviews.llvm.org/D128690
More information about the cfe-commits
mailing list