diff options
| author | Jacob Pratt <jacob@jhpratt.dev> | 2025-04-13 17:37:52 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-13 17:37:52 -0400 |
| commit | 7f691d28f16222fe978ceccde4d1c8c7f54efdfa (patch) | |
| tree | e77a60f40bc660c81d317fb600ff73117149bce5 /compiler/rustc_lint_defs/src | |
| parent | 60c76b9dfd6e52f6605e0a63b7a33ad09dab96d3 (diff) | |
| parent | 8866af388497e9ed3254147c015379d5d6cdb054 (diff) | |
| download | rust-7f691d28f16222fe978ceccde4d1c8c7f54efdfa.tar.gz rust-7f691d28f16222fe978ceccde4d1c8c7f54efdfa.zip | |
Rollup merge of #139001 - folkertdev:naked-function-rustic-abi, r=traviscross,compiler-errors
add `naked_functions_rustic_abi` feature gate
tracking issue: https://github.com/rust-lang/rust/issues/138997
Because the details of the rust abi are unstable, and a naked function must match its stated ABI, this feature gate keeps naked functions with a rustic abi ("Rust", "rust-cold", "rust-call" and "rust-intrinsic") unstable.
r? ````@traviscross````
Diffstat (limited to 'compiler/rustc_lint_defs/src')
| -rw-r--r-- | compiler/rustc_lint_defs/src/builtin.rs | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/compiler/rustc_lint_defs/src/builtin.rs b/compiler/rustc_lint_defs/src/builtin.rs index 8a761a0a096..b25d2a30681 100644 --- a/compiler/rustc_lint_defs/src/builtin.rs +++ b/compiler/rustc_lint_defs/src/builtin.rs @@ -110,7 +110,6 @@ declare_lint_pass! { UNCONDITIONAL_PANIC, UNCONDITIONAL_RECURSION, UNCOVERED_PARAM_IN_PROJECTION, - UNDEFINED_NAKED_FUNCTION_ABI, UNEXPECTED_CFGS, UNFULFILLED_LINT_EXPECTATIONS, UNINHABITED_STATIC, @@ -2831,39 +2830,6 @@ declare_lint! { } declare_lint! { - /// The `undefined_naked_function_abi` lint detects naked function definitions that - /// either do not specify an ABI or specify the Rust ABI. - /// - /// ### Example - /// - /// ```rust - /// #![feature(asm_experimental_arch, naked_functions)] - /// - /// use std::arch::naked_asm; - /// - /// #[naked] - /// pub fn default_abi() -> u32 { - /// unsafe { naked_asm!(""); } - /// } - /// - /// #[naked] - /// pub extern "Rust" fn rust_abi() -> u32 { - /// unsafe { naked_asm!(""); } - /// } - /// ``` - /// - /// {{produces}} - /// - /// ### Explanation - /// - /// The Rust ABI is currently undefined. Therefore, naked functions should - /// specify a non-Rust ABI. - pub UNDEFINED_NAKED_FUNCTION_ABI, - Warn, - "undefined naked function ABI" -} - -declare_lint! { /// The `ineffective_unstable_trait_impl` lint detects `#[unstable]` attributes which are not used. /// /// ### Example |
