Compute by owner instead of HirId.

This commit is contained in:
Camille GILLOT
2022-09-29 21:07:06 +02:00
parent 26e5fe9e85
commit d08669c4fa
5 changed files with 148 additions and 26 deletions

View File

@@ -274,9 +274,10 @@ rustc_queries! {
separate_provide_extern
}
query shallow_lint_levels_on(key: HirId) -> rustc_middle::lint::ShallowLintLevelMap {
query shallow_lint_levels_on(key: hir::OwnerId) -> rustc_middle::lint::ShallowLintLevelMap {
eval_always // fetches `resolutions`
arena_cache
desc { |tcx| "looking up lint levels for `{}`", key }
desc { |tcx| "looking up lint levels for `{}`", tcx.def_path_str(key.to_def_id()) }
}
query lint_expectations(_: ()) -> Vec<(LintExpectationId, LintExpectation)> {