[PATCH] D39050: Add index-while-building support to Clang

Nathan Hawes via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 6 18:49:07 PST 2017

nathawes added inline comments.

Comment at: lib/Index/IndexRecordHasher.cpp:103
+      COMBINE_HASH(Hasher.hash(param->getType()));
+    }
+    return Hash;
arphaman wrote:
> Should you hash the return type as well?
The return type doesn't affect the function's USR, so there's no need to consider it when hashing the function decl. The hashing here is happening per decl occurrence (source offset + role set + Decl) collected by the index AST walker, so changing the return type will still change the record hash when any decl occurrences it contains are hashed in.


More information about the cfe-commits mailing list