Skip to content

Commit 309d867

Browse files
committed
Stabilize cfg_target_abi
1 parent 090d5ea commit 309d867

File tree

13 files changed

+32
-93
lines changed

13 files changed

+32
-93
lines changed

compiler/rustc_feature/src/accepted.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,8 @@ declare_features! (
8484
(accepted, cfg_doctest, "1.40.0", Some(62210)),
8585
/// Enables `#[cfg(panic = "...")]` config key.
8686
(accepted, cfg_panic, "1.60.0", Some(77443)),
87+
/// Allows `cfg(target_abi = "...")`.
88+
(accepted, cfg_target_abi, "CURRENT_RUSTC_VERSION", Some(80970)),
8789
/// Allows `cfg(target_feature = "...")`.
8890
(accepted, cfg_target_feature, "1.27.0", Some(29717)),
8991
/// Allows `cfg(target_vendor = "...")`.

compiler/rustc_feature/src/builtin_attrs.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ pub type GatedCfg = (Symbol, Symbol, GateFn);
2525
const GATED_CFGS: &[GatedCfg] = &[
2626
// (name in cfg, feature, function to check if the feature is enabled)
2727
(sym::overflow_checks, sym::cfg_overflow_checks, cfg_fn!(cfg_overflow_checks)),
28-
(sym::target_abi, sym::cfg_target_abi, cfg_fn!(cfg_target_abi)),
2928
(sym::target_thread_local, sym::cfg_target_thread_local, cfg_fn!(cfg_target_thread_local)),
3029
(
3130
sym::target_has_atomic_equal_alignment,

compiler/rustc_feature/src/unstable.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -373,8 +373,6 @@ declare_features! (
373373
(unstable, cfg_sanitize, "1.41.0", Some(39699)),
374374
/// Allows `cfg(sanitizer_cfi_generalize_pointers)` and `cfg(sanitizer_cfi_normalize_integers)`.
375375
(unstable, cfg_sanitizer_cfi, "CURRENT_RUSTC_VERSION", Some(89653)),
376-
/// Allows `cfg(target_abi = "...")`.
377-
(unstable, cfg_target_abi, "1.55.0", Some(80970)),
378376
/// Allows `cfg(target(abi = "..."))`.
379377
(unstable, cfg_target_compact, "1.63.0", Some(96901)),
380378
/// Allows `cfg(target_has_atomic_load_store = "...")`.

compiler/rustc_target/src/spec/targets/armv6_unknown_freebsd.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ pub fn target() -> Target {
88
arch: "arm".into(),
99
options: TargetOptions {
1010
abi: "eabihf".into(),
11-
// FIXME: change env to "gnu" when cfg_target_abi becomes stable
12-
env: "gnueabihf".into(),
11+
env: "gnu".into(),
1312
features: "+v6,+vfp2,-d32".into(),
1413
max_atomic_width: Some(64),
1514
mcount: "\u{1}__gnu_mcount_nc".into(),

compiler/rustc_target/src/spec/targets/armv6_unknown_netbsd_eabihf.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@ pub fn target() -> Target {
88
arch: "arm".into(),
99
options: TargetOptions {
1010
abi: "eabihf".into(),
11-
// FIXME: remove env when cfg_target_abi becomes stable
12-
env: "eabihf".into(),
1311
features: "+v6,+vfp2,-d32".into(),
1412
max_atomic_width: Some(64),
1513
mcount: "__mcount".into(),

compiler/rustc_target/src/spec/targets/armv7_unknown_freebsd.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ pub fn target() -> Target {
88
arch: "arm".into(),
99
options: TargetOptions {
1010
abi: "eabihf".into(),
11-
// FIXME: change env to "gnu" when cfg_target_abi becomes stable
12-
env: "gnueabihf".into(),
11+
env: "gnu".into(),
1312
features: "+v7,+vfp3,-d32,+thumb2,-neon".into(),
1413
max_atomic_width: Some(64),
1514
mcount: "\u{1}__gnu_mcount_nc".into(),

compiler/rustc_target/src/spec/targets/armv7_unknown_netbsd_eabihf.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@ pub fn target() -> Target {
88
arch: "arm".into(),
99
options: TargetOptions {
1010
abi: "eabihf".into(),
11-
// FIXME: remove env when cfg_target_abi becomes stable
12-
env: "eabihf".into(),
1311
features: "+v7,+vfp3,-d32,+thumb2,-neon".into(),
1412
max_atomic_width: Some(64),
1513
mcount: "__mcount".into(),

library/unwind/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#![feature(link_cfg)]
44
#![feature(staged_api)]
55
#![feature(c_unwind)]
6-
#![feature(cfg_target_abi)]
6+
#![cfg_attr(bootstrap, feature(cfg_target_abi))]
77
#![feature(strict_provenance)]
88
#![cfg_attr(not(target_env = "msvc"), feature(libc))]
99
#![allow(internal_features)]

tests/ui/cfg/cfg-target-abi.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
// run-pass
2-
#![feature(cfg_target_abi)]
32

43
#[cfg(target_abi = "eabihf")]
54
pub fn main() {

tests/ui/check-cfg/well-known-values.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
#![feature(cfg_overflow_checks)]
1111
#![feature(cfg_relocation_model)]
1212
#![feature(cfg_sanitize)]
13-
#![feature(cfg_target_abi)]
1413
#![feature(cfg_target_has_atomic)]
1514
#![feature(cfg_target_has_atomic_equal_alignment)]
1615
#![feature(cfg_target_thread_local)]

0 commit comments

Comments
 (0)