about summary refs log tree commit diff
path: root/compiler/rustc_const_eval/src
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2023-08-20 08:43:32 +0200
committerRalf Jung <post@ralfj.de>2023-08-20 15:52:40 +0200
commit807e5b8022923ce4c569c65bf79796cfa3939d6a (patch)
tree388ccd6a8c35c379f375271ac7f4a2911be6e1f3 /compiler/rustc_const_eval/src
parentac3bca24b72ff31c6059c537bbc913c60acfaa40 (diff)
downloadrust-807e5b8022923ce4c569c65bf79796cfa3939d6a.tar.gz
rust-807e5b8022923ce4c569c65bf79796cfa3939d6a.zip
avoid return in tail position
Co-authored-by: fee1-dead <ent3rm4n@gmail.com>
Diffstat (limited to 'compiler/rustc_const_eval/src')
-rw-r--r--compiler/rustc_const_eval/src/const_eval/machine.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_const_eval/src/const_eval/machine.rs b/compiler/rustc_const_eval/src/const_eval/machine.rs
index cf010864018..f16aea6f34b 100644
--- a/compiler/rustc_const_eval/src/const_eval/machine.rs
+++ b/compiler/rustc_const_eval/src/const_eval/machine.rs
@@ -468,7 +468,7 @@ impl<'mir, 'tcx> interpret::Machine<'mir, 'tcx> for CompileTimeInterpreter<'mir,
         let msg = Symbol::intern(msg);
         let span = ecx.find_closest_untracked_caller_location();
         let (file, line, col) = ecx.location_triple_for_span(span);
-        return Err(ConstEvalErrKind::Panic { msg, file, line, col }.into());
+        Err(ConstEvalErrKind::Panic { msg, file, line, col }.into())
     }
 
     fn call_intrinsic(