From 369a795ef7de85f12c7a83559ca5c134a500f451 Mon Sep 17 00:00:00 2001 From: Trevor Gross Date: Tue, 26 Nov 2024 15:55:32 -0500 Subject: [PATCH] cleanup: Remove the `const-extern-fn` feature Since moving from a feature to a `cfg`, this feature is unneeded. Remove it in 1.0. Not intended for backport. --- Cargo.toml | 6 +----- ci/verify-build.sh | 1 - src/macros.rs | 2 +- 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 107ee46ea3909..508dc104d6da4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -135,14 +135,10 @@ cargo-args = ["-Zbuild-std=core"] rustc-std-workspace-core = { version = "1.0.0", optional = true } [features] -default = ["const-extern-fn", "std"] +default = ["std"] std = [] rustc-dep-of-std = ["rustc-std-workspace-core"] extra_traits = [] -# `const-extern-function` is deprecated and no longer does anything -# FIXME(1.0): remove this completely -const-extern-fn = [] - [workspace] members = ["libc-test"] diff --git a/ci/verify-build.sh b/ci/verify-build.sh index b88e214fb34d1..7d3e556e0c554 100755 --- a/ci/verify-build.sh +++ b/ci/verify-build.sh @@ -62,7 +62,6 @@ test_target() { # Test with expected combinations of features $cmd - $cmd --features const-extern-fn $cmd --features extra_traits # Test again without default features, i.e. without "std" diff --git a/src/macros.rs b/src/macros.rs index fe103968801a4..b5198008d9572 100644 --- a/src/macros.rs +++ b/src/macros.rs @@ -169,7 +169,7 @@ macro_rules! e { // This is a pretty horrible hack to allow us to conditionally mark // some functions as 'const', without requiring users of this macro -// to care about the "const-extern-fn" feature. +// to care about the "const-extern-fn" feature (or `const_extern_fn` config). // // When 'const-extern-fn' is enabled, we emit the captured 'const' keyword // in the expanded function.