af1ca153d4
Some more refactorings towards removing driver queries Follow up to https://github.com/rust-lang/rust/pull/127184 ## Custom driver breaking change The `after_analysis` callback is changed to accept `TyCtxt` instead of `Queries`. The only safe query in `Queries` to call at this point is `global_ctxt()` which allows you to enter the `TyCtxt` either way. To fix your custom driver, replace the `queries: &'tcx Queries<'tcx>` argument with `tcx: TyCtxt<'tcx>` and remove your `queries.global_ctxt().unwrap().enter(|tcx| { ... })` call and only keep the contents of the closure. ## Custom driver deprecation The `after_crate_root_parsing` callback is now deprecated. Several custom drivers are incorrectly calling `queries.global_ctxt()` from inside of it, which causes some driver code to be skipped. As such I would like to either remove it in the future or if custom drivers still need it, change it to accept an `&rustc_ast::Crate` instead. |
||
---|---|---|
.. | ||
check_abi.rs | ||
check_allocation.rs | ||
check_attribute.rs | ||
check_binop.rs | ||
check_crate_defs.rs | ||
check_def_ty.rs | ||
check_defs.rs | ||
check_foreign.rs | ||
check_instance.rs | ||
check_intrinsics.rs | ||
check_item_kind.rs | ||
check_normalization.rs | ||
check_trait_queries.rs | ||
check_transform.rs | ||
check_ty_fold.rs | ||
compilation-result.rs | ||
crate-info.rs | ||
projections.rs | ||
smir_internal.rs | ||
smir_serde.rs | ||
smir_visitor.rs |