mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-06 08:36:52 -04:00
e4097f672e
Clean up `TyCtxt::needs_crate_hash` usage and rename it to `needs_hir_hash`. While reviewing `crate_hash` query usage for https://github.com/rust-lang/rust/pull/155871, the `needs_crate_hash` function turned out to be the cause of unnecessary calls to the query. The `needs_crate_hash` name is easy to mistake for the functionality of "needs the crate_hash query". This PR removes the usage of `needs_crate_hash` where it was not appropriate and renames the function to `needs_hir_hash` which better reflects its functionality.