about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2024-12-02 11:02:22 +0100
committerRalf Jung <post@ralfj.de>2024-12-11 22:18:51 +0100
commit60eca2c5758a736559a60b7552833d20b0895763 (patch)
treed63365f463b918f30b9d63aca6ec7a7a9ad6da5d /compiler/rustc_codegen_llvm/src
parentd6ddc73daeb27fc3b5b009105185c44621c3c7cb (diff)
downloadrust-60eca2c5758a736559a60b7552833d20b0895763.tar.gz
rust-60eca2c5758a736559a60b7552833d20b0895763.zip
apply review feedback
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
-rw-r--r--compiler/rustc_codegen_llvm/src/llvm_util.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/compiler/rustc_codegen_llvm/src/llvm_util.rs b/compiler/rustc_codegen_llvm/src/llvm_util.rs
index 3f53856f98d..bfec7d708cf 100644
--- a/compiler/rustc_codegen_llvm/src/llvm_util.rs
+++ b/compiler/rustc_codegen_llvm/src/llvm_util.rs
@@ -717,12 +717,14 @@ pub(crate) fn global_llvm_features(
                             sess.dcx().emit_warn(unknown_feature);
                         }
                         Some((_, stability, _)) => {
-                            if let Err(reason) = stability.compute(&sess.target).allow_toggle() {
+                            if let Err(reason) =
+                                stability.compute_toggleability(&sess.target).allow_toggle()
+                            {
                                 sess.dcx().emit_warn(ForbiddenCTargetFeature { feature, reason });
                             } else if stability.requires_nightly().is_some() {
-                                // An unstable feature. Warn about using it. (It makes little sense
+                                // An unstable feature. Warn about using it. It makes little sense
                                 // to hard-error here since we just warn about fully unknown
-                                // features above).
+                                // features above.
                                 sess.dcx().emit_warn(UnstableCTargetFeature { feature });
                             }
                         }