diff options
| author | Boxy <supbscripter@gmail.com> | 2023-04-27 07:52:17 +0100 |
|---|---|---|
| committer | Boxy <supbscripter@gmail.com> | 2023-04-27 08:35:19 +0100 |
| commit | 842419712a9ed7be166bfdac2d5588356191dabb (patch) | |
| tree | 0afe598d0f7ac4d14ec023a1235b95e42331a3db /compiler/rustc_const_eval/src | |
| parent | f04b8fe0af291a444ecfcf774337966a5cc9d7db (diff) | |
| download | rust-842419712a9ed7be166bfdac2d5588356191dabb.tar.gz rust-842419712a9ed7be166bfdac2d5588356191dabb.zip | |
rename `needs_subst` to `has_param`
Diffstat (limited to 'compiler/rustc_const_eval/src')
| -rw-r--r-- | compiler/rustc_const_eval/src/interpret/util.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/rustc_const_eval/src/interpret/util.rs b/compiler/rustc_const_eval/src/interpret/util.rs index 7cb19744987..22bdd4d2c3f 100644 --- a/compiler/rustc_const_eval/src/interpret/util.rs +++ b/compiler/rustc_const_eval/src/interpret/util.rs @@ -14,7 +14,7 @@ where T: TypeVisitable<TyCtxt<'tcx>>, { debug!("ensure_monomorphic_enough: ty={:?}", ty); - if !ty.needs_subst() { + if !ty.has_param() { return Ok(()); } @@ -27,7 +27,7 @@ where type BreakTy = FoundParam; fn visit_ty(&mut self, ty: Ty<'tcx>) -> ControlFlow<Self::BreakTy> { - if !ty.needs_subst() { + if !ty.has_param() { return ControlFlow::Continue(()); } @@ -46,7 +46,7 @@ where // are used and require substitution. // Just in case there are closures or generators within this subst, // recurse. - if unused_params.is_used(index) && subst.needs_subst() { + if unused_params.is_used(index) && subst.has_param() { return subst.visit_with(self); } } |
