1
Fork 0

Auto merge of #120843 - matthiaskrgr:rollup-med37z5, r=matthiaskrgr

Rollup of 8 pull requests

Successful merges:

 - #113671 (Make privacy visitor use types more (instead of HIR))
 - #120308 (core/time: avoid divisions in Duration::new)
 - #120693 (Invert diagnostic lints.)
 - #120704 (A drive-by rewrite of `give_region_a_name()`)
 - #120809 (Use `transmute_unchecked` in `NonZero::new`.)
 - #120817 (Fix more `ty::Error` ICEs in MIR passes)
 - #120828 (Fix `ErrorGuaranteed` unsoundness with stash/steal.)
 - #120831 (Startup objects disappearing from sysroot)

r? `@ghost`
`@rustbot` modify labels: rollup
This commit is contained in:
bors 2024-02-09 15:34:48 +00:00
commit e28fae52d9
155 changed files with 674 additions and 840 deletions

View file

@ -5,9 +5,9 @@ Rust MIR: a lowered representation of Rust.
*/
#![allow(internal_features)]
#![allow(rustc::diagnostic_outside_of_impl)]
#![feature(rustdoc_internals)]
#![doc(rust_logo)]
#![deny(rustc::untranslatable_diagnostic)]
#![feature(assert_matches)]
#![feature(box_patterns)]
#![feature(decl_macro)]

View file

@ -60,6 +60,8 @@ impl<'tcx> MirPass<'tcx> for Validator {
ty::Closure(..) => Abi::RustCall,
ty::CoroutineClosure(..) => Abi::RustCall,
ty::Coroutine(..) => Abi::Rust,
// No need to do MIR validation on error bodies
ty::Error(_) => return,
_ => {
span_bug!(body.span, "unexpected body ty: {:?} phase {:?}", body_ty, mir_phase)
}