about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--compiler/rustc_session/src/parse.rs2
-rw-r--r--compiler/rustc_type_ir/src/infer_ctxt.rs7
2 files changed, 2 insertions, 7 deletions
diff --git a/compiler/rustc_session/src/parse.rs b/compiler/rustc_session/src/parse.rs
index ea7a524efe6..9097b27b86c 100644
--- a/compiler/rustc_session/src/parse.rs
+++ b/compiler/rustc_session/src/parse.rs
@@ -209,7 +209,7 @@ pub fn add_feature_diagnostics_for_issue<G: EmissionGuarantee>(
 /// This is basically the same as `feature_err_issue`
 /// but without the feature issue note. If we can do a lookup for issue number from feature name,
 /// then we should directly use `feature_err_issue` for ambiguity error of
-/// #[unstable_feature_bound].
+/// `#[unstable_feature_bound]`.
 #[track_caller]
 pub fn feature_err_unstable_feature_bound(
     sess: &Session,
diff --git a/compiler/rustc_type_ir/src/infer_ctxt.rs b/compiler/rustc_type_ir/src/infer_ctxt.rs
index b558d016448..e86a2305e23 100644
--- a/compiler/rustc_type_ir/src/infer_ctxt.rs
+++ b/compiler/rustc_type_ir/src/infer_ctxt.rs
@@ -319,11 +319,6 @@ where
     // Note: `feature_bound_holds_in_crate` does not consider a feature to be enabled
     // if we are in std/core even if there is a corresponding `feature` attribute on the crate.
 
-    if (infcx.typing_mode() == TypingMode::PostAnalysis)
+    (infcx.typing_mode() == TypingMode::PostAnalysis)
         || infcx.cx().features().feature_bound_holds_in_crate(symbol)
-    {
-        return true;
-    } else {
-        return false;
-    }
 }