Decouple trait impls of different traits wrt incremental

This commit is contained in:
Oli Scherer
2025-03-27 11:48:06 +00:00
parent 97ea17b71a
commit a7b687c26e
5 changed files with 14 additions and 6 deletions

View File

@@ -1502,6 +1502,11 @@ rustc_queries! {
desc { "finding local trait impls" }
}
/// Return all `impl` blocks of the given trait in the current crate.
query local_trait_impls(trait_id: DefId) -> &'tcx [LocalDefId] {
desc { "finding local trait impls of `{}`", tcx.def_path_str(trait_id) }
}
/// Given a trait `trait_id`, return all known `impl` blocks.
query trait_impls_of(trait_id: DefId) -> &'tcx ty::trait_def::TraitImpls {
arena_cache