Auto merge of #122721 - oli-obk:merge_queries, r=davidtwco

Replace `mir_built` query with a hook and use mir_const everywhere instead

A small perf improvement due to less dep graph handling.

Mostly just a cleanup to get rid of one of our many mir queries
This commit is contained in:
bors
2024-03-25 01:33:46 +00:00
12 changed files with 62 additions and 81 deletions

View File

@@ -22,14 +22,14 @@ mod errors;
pub mod lints;
mod thir;
use rustc_middle::query::Providers;
use rustc_middle::util::Providers;
rustc_fluent_macro::fluent_messages! { "../messages.ftl" }
pub fn provide(providers: &mut Providers) {
providers.check_match = thir::pattern::check_match;
providers.lit_to_const = thir::constant::lit_to_const;
providers.mir_built = build::mir_built;
providers.hooks.build_mir = build::mir_build;
providers.closure_saved_names_of_captured_variables =
build::closure_saved_names_of_captured_variables;
providers.check_unsafety = check_unsafety::check_unsafety;