diff options
| author | bors <bors@rust-lang.org> | 2024-05-02 18:24:38 +0000 | 
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-05-02 18:24:38 +0000 | 
| commit | 79734f1db8dbe322192dea32c0f6b80ab14c4c1d (patch) | |
| tree | fdc9824b1cdc214c88425fb8980caf978c38c3d9 /compiler/rustc_mir_build/src | |
| parent | a8773d53bea79d80e5e6ea0e602130be7faa6cbe (diff) | |
| parent | a248411a9735dcfe9ba666fd293b3726fe490e43 (diff) | |
| download | rust-79734f1db8dbe322192dea32c0f6b80ab14c4c1d.tar.gz rust-79734f1db8dbe322192dea32c0f6b80ab14c4c1d.zip | |
Auto merge of #124629 - matthiaskrgr:rollup-gttvzrg, r=matthiaskrgr
Rollup of 7 pull requests Successful merges: - #124138 (Ignore LLVM ABI in dlltool tests since those targets don't use dlltool) - #124414 (remove extraneous note on `UnableToRunDsymutil` diagnostic) - #124579 (Align: add bytes_usize and bits_usize) - #124622 (Cleanup: Rid the `rmake` test runners of `extern crate run_make_support;`) - #124623 (shallow resolve in orphan check) - #124624 (Use `tcx.types.unit` instead of `Ty::new_unit(tcx)`) - #124627 (interpret: hide some reexports in rustdoc) r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_mir_build/src')
| -rw-r--r-- | compiler/rustc_mir_build/src/build/mod.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_mir_build/src/thir/cx/mod.rs | 4 | 
2 files changed, 3 insertions, 3 deletions
| diff --git a/compiler/rustc_mir_build/src/build/mod.rs b/compiler/rustc_mir_build/src/build/mod.rs index 3c18afe1a78..d6e6cc957b4 100644 --- a/compiler/rustc_mir_build/src/build/mod.rs +++ b/compiler/rustc_mir_build/src/build/mod.rs @@ -997,7 +997,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> { match self.unit_temp { Some(tmp) => tmp, None => { - let ty = Ty::new_unit(self.tcx); + let ty = self.tcx.types.unit; let fn_span = self.fn_span; let tmp = self.temp(ty, fn_span); self.unit_temp = Some(tmp); diff --git a/compiler/rustc_mir_build/src/thir/cx/mod.rs b/compiler/rustc_mir_build/src/thir/cx/mod.rs index f4f591d15b9..79738b54035 100644 --- a/compiler/rustc_mir_build/src/thir/cx/mod.rs +++ b/compiler/rustc_mir_build/src/thir/cx/mod.rs @@ -15,7 +15,7 @@ use rustc_hir::HirId; use rustc_hir::Node; use rustc_middle::middle::region; use rustc_middle::thir::*; -use rustc_middle::ty::{self, RvalueScopes, Ty, TyCtxt}; +use rustc_middle::ty::{self, RvalueScopes, TyCtxt}; pub(crate) fn thir_body( tcx: TyCtxt<'_>, @@ -39,7 +39,7 @@ pub(crate) fn thir_body( // It will always be `()` in this case. if tcx.is_coroutine(owner_def.to_def_id()) && body.params.is_empty() { cx.thir.params.push(Param { - ty: Ty::new_unit(tcx), + ty: tcx.types.unit, pat: None, ty_span: None, self_kind: None, | 
