about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEllen <supbscripter@gmail.com>2021-03-03 10:04:49 +0000
committerEllen <supbscripter@gmail.com>2021-03-03 10:04:49 +0000
commit356ce96fe1fa630e660381448ce9ecb8defd3008 (patch)
treeb9ed5e1da49abce846ac964ee0c861e7662f64b2
parent342ec83629b71ab3d63b55e193fa43b72857a434 (diff)
downloadrust-356ce96fe1fa630e660381448ce9ecb8defd3008.tar.gz
rust-356ce96fe1fa630e660381448ce9ecb8defd3008.zip
Remove extraneous return statement
-rw-r--r--compiler/rustc_trait_selection/src/traits/const_evaluatable.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs b/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs
index 7e0c74c8d2b..49575f2116f 100644
--- a/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs
+++ b/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs
@@ -162,10 +162,10 @@ pub fn is_const_evaluatable<'cx, 'tcx>(
     debug!(?concrete, "is_const_evaluatable");
     match concrete {
         Err(ErrorHandled::TooGeneric) => {
-            return Err(match substs.has_infer_types_or_consts() {
+            Err(match substs.has_infer_types_or_consts() {
                 true => NotConstEvaluatable::MentionsInfer,
                 false => NotConstEvaluatable::MentionsParam,
-            });
+            })
         }
         Err(ErrorHandled::Linted) => {
             infcx.tcx.sess.delay_span_bug(span, "constant in type had error reported as lint");