about summary refs log tree commit diff
path: root/compiler
diff options
context:
space:
mode:
Diffstat (limited to 'compiler')
-rw-r--r--compiler/rustc_feature/src/active.rs2
-rw-r--r--compiler/rustc_lint_defs/src/builtin.rs4
-rw-r--r--compiler/rustc_target/src/spec/abi.rs53
3 files changed, 13 insertions, 46 deletions
diff --git a/compiler/rustc_feature/src/active.rs b/compiler/rustc_feature/src/active.rs
index 052d312d9a0..f046022b842 100644
--- a/compiler/rustc_feature/src/active.rs
+++ b/compiler/rustc_feature/src/active.rs
@@ -311,7 +311,7 @@ declare_features! (
     (active, async_closure, "1.37.0", Some(62290), None),
     /// Allows async functions to be declared, implemented, and used in traits.
     (incomplete, async_fn_in_trait, "1.66.0", Some(91611), None),
-    /// Allows `extern "C-unwind" fn` to enable unwinding across ABI boundaries.
+    /// Treat `extern "C"` function as nounwind.
     (active, c_unwind, "1.52.0", Some(74990), None),
     /// Allows using C-variadics.
     (active, c_variadic, "1.34.0", Some(44930), None),
diff --git a/compiler/rustc_lint_defs/src/builtin.rs b/compiler/rustc_lint_defs/src/builtin.rs
index a3d7bd3ef59..6fe15e21d94 100644
--- a/compiler/rustc_lint_defs/src/builtin.rs
+++ b/compiler/rustc_lint_defs/src/builtin.rs
@@ -4014,7 +4014,6 @@ declare_lint! {
     /// ### Example
     ///
     /// ```rust
-    /// #![feature(c_unwind)]
     /// #![warn(ffi_unwind_calls)]
     ///
     /// extern "C-unwind" {
@@ -4037,8 +4036,7 @@ declare_lint! {
     /// that desire this ability it is therefore necessary to avoid such calls.
     pub FFI_UNWIND_CALLS,
     Allow,
-    "call to foreign functions or function pointers with FFI-unwind ABI",
-    @feature_gate = sym::c_unwind;
+    "call to foreign functions or function pointers with FFI-unwind ABI"
 }
 
 declare_lint! {
diff --git a/compiler/rustc_target/src/spec/abi.rs b/compiler/rustc_target/src/spec/abi.rs
index 5582d909f6b..eb3f66ac308 100644
--- a/compiler/rustc_target/src/spec/abi.rs
+++ b/compiler/rustc_target/src/spec/abi.rs
@@ -148,8 +148,9 @@ pub fn is_enabled(
 pub fn is_stable(name: &str) -> Result<(), AbiDisabled> {
     match name {
         // Stable
-        "Rust" | "C" | "cdecl" | "stdcall" | "fastcall" | "aapcs" | "win64" | "sysv64"
-        | "system" | "efiapi" => Ok(()),
+        "Rust" | "C" | "C-unwind" | "cdecl" | "cdecl-unwind" | "stdcall" | "stdcall-unwind"
+        | "fastcall" | "fastcall-unwind" | "aapcs" | "aapcs-unwind" | "win64" | "win64-unwind"
+        | "sysv64" | "sysv64-unwind" | "system" | "system-unwind" | "efiapi" => Ok(()),
         "rust-intrinsic" => Err(AbiDisabled::Unstable {
             feature: sym::intrinsics,
             explain: "intrinsics are subject to change",
@@ -162,10 +163,18 @@ pub fn is_stable(name: &str) -> Result<(), AbiDisabled> {
             feature: sym::abi_vectorcall,
             explain: "vectorcall is experimental and subject to change",
         }),
+        "vectorcall-unwind" => Err(AbiDisabled::Unstable {
+            feature: sym::abi_vectorcall,
+            explain: "vectorcall-unwind ABI is experimental and subject to change",
+        }),
         "thiscall" => Err(AbiDisabled::Unstable {
             feature: sym::abi_thiscall,
             explain: "thiscall is experimental and subject to change",
         }),
+        "thiscall-unwind" => Err(AbiDisabled::Unstable {
+            feature: sym::abi_thiscall,
+            explain: "thiscall-unwind ABI is experimental and subject to change",
+        }),
         "rust-call" => Err(AbiDisabled::Unstable {
             feature: sym::unboxed_closures,
             explain: "rust-call ABI is subject to change",
@@ -202,46 +211,6 @@ pub fn is_stable(name: &str) -> Result<(), AbiDisabled> {
             feature: sym::abi_c_cmse_nonsecure_call,
             explain: "C-cmse-nonsecure-call ABI is experimental and subject to change",
         }),
-        "C-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "C-unwind ABI is experimental and subject to change",
-        }),
-        "stdcall-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "stdcall-unwind ABI is experimental and subject to change",
-        }),
-        "system-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "system-unwind ABI is experimental and subject to change",
-        }),
-        "thiscall-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "thiscall-unwind ABI is experimental and subject to change",
-        }),
-        "cdecl-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "cdecl-unwind ABI is experimental and subject to change",
-        }),
-        "fastcall-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "fastcall-unwind ABI is experimental and subject to change",
-        }),
-        "vectorcall-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "vectorcall-unwind ABI is experimental and subject to change",
-        }),
-        "aapcs-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "aapcs-unwind ABI is experimental and subject to change",
-        }),
-        "win64-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "win64-unwind ABI is experimental and subject to change",
-        }),
-        "sysv64-unwind" => Err(AbiDisabled::Unstable {
-            feature: sym::c_unwind,
-            explain: "sysv64-unwind ABI is experimental and subject to change",
-        }),
         "wasm" => Err(AbiDisabled::Unstable {
             feature: sym::wasm_abi,
             explain: "wasm ABI is experimental and subject to change",