diff options
| author | Michael Goulet <michael@errs.io> | 2024-09-11 14:58:08 -0400 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2024-09-11 17:52:53 -0400 |
| commit | 6d064295c8fb7413cb0500289f922f8d7feb38dc (patch) | |
| tree | 1c0746343653491bcf5e0290b88db58bfeb253d2 /compiler/rustc_const_eval/src | |
| parent | 5a2dd7d4f3210629e65879aeecbe643ba3b86bb4 (diff) | |
| download | rust-6d064295c8fb7413cb0500289f922f8d7feb38dc.tar.gz rust-6d064295c8fb7413cb0500289f922f8d7feb38dc.zip | |
clippy::useless_conversion
Diffstat (limited to 'compiler/rustc_const_eval/src')
| -rw-r--r-- | compiler/rustc_const_eval/src/const_eval/eval_queries.rs | 7 | ||||
| -rw-r--r-- | compiler/rustc_const_eval/src/interpret/call.rs | 2 |
2 files changed, 2 insertions, 7 deletions
diff --git a/compiler/rustc_const_eval/src/const_eval/eval_queries.rs b/compiler/rustc_const_eval/src/const_eval/eval_queries.rs index 7ccebd83f24..da4173f9032 100644 --- a/compiler/rustc_const_eval/src/const_eval/eval_queries.rs +++ b/compiler/rustc_const_eval/src/const_eval/eval_queries.rs @@ -75,12 +75,7 @@ fn eval_body_using_ecx<'tcx, R: InterpretationResult<'tcx>>( // This can't use `init_stack_frame` since `body` is not a function, // so computing its ABI would fail. It's also not worth it since there are no arguments to pass. - ecx.push_stack_frame_raw( - cid.instance, - body, - &ret.clone().into(), - StackPopCleanup::Root { cleanup: false }, - )?; + ecx.push_stack_frame_raw(cid.instance, body, &ret, StackPopCleanup::Root { cleanup: false })?; ecx.storage_live_for_always_live_locals()?; // The main interpreter loop. diff --git a/compiler/rustc_const_eval/src/interpret/call.rs b/compiler/rustc_const_eval/src/interpret/call.rs index 568a9a3a637..5687e72569f 100644 --- a/compiler/rustc_const_eval/src/interpret/call.rs +++ b/compiler/rustc_const_eval/src/interpret/call.rs @@ -823,7 +823,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> { (Abi::Rust, fn_abi), &[FnArg::Copy(arg.into())], false, - &ret.into(), + &ret, Some(target), unwind, ) |
