diff options
| author | Michael Goulet <michael@errs.io> | 2025-02-28 01:27:04 +0000 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2025-02-28 01:27:08 +0000 |
| commit | 371c073ecff1d9e9ad6adb46e25bdbc53834be61 (patch) | |
| tree | 1575f8291ab4fec107ea86099bd09da7701479ea /compiler/rustc_middle/src | |
| parent | f45d4acf1bb635aa010f19f8a749eed8293203b3 (diff) | |
| download | rust-371c073ecff1d9e9ad6adb46e25bdbc53834be61.tar.gz rust-371c073ecff1d9e9ad6adb46e25bdbc53834be61.zip | |
Use mk_ty_from_kind a bit less, clean up lifetime handling in borrowck
Diffstat (limited to 'compiler/rustc_middle/src')
| -rw-r--r-- | compiler/rustc_middle/src/ty/codec.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_middle/src/ty/sty.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_middle/src/ty/codec.rs b/compiler/rustc_middle/src/ty/codec.rs index 41958949836..fe42a224d9f 100644 --- a/compiler/rustc_middle/src/ty/codec.rs +++ b/compiler/rustc_middle/src/ty/codec.rs @@ -224,7 +224,7 @@ impl<'tcx, D: TyDecoder<I = TyCtxt<'tcx>>> Decodable<D> for Ty<'tcx> { }) } else { let tcx = decoder.interner(); - tcx.mk_ty_from_kind(rustc_type_ir::TyKind::decode(decoder)) + tcx.mk_ty_from_kind(ty::TyKind::decode(decoder)) } } } diff --git a/compiler/rustc_middle/src/ty/sty.rs b/compiler/rustc_middle/src/ty/sty.rs index d5617adf26b..09e372c3e0f 100644 --- a/compiler/rustc_middle/src/ty/sty.rs +++ b/compiler/rustc_middle/src/ty/sty.rs @@ -461,7 +461,7 @@ impl<'tcx> Ty<'tcx> { #[inline] pub fn new_param(tcx: TyCtxt<'tcx>, index: u32, name: Symbol) -> Ty<'tcx> { - tcx.mk_ty_from_kind(Param(ParamTy { index, name })) + Ty::new(tcx, Param(ParamTy { index, name })) } #[inline] |
