Skip to content

Commit 506e75c

Browse files
committed
Auto merge of #85109 - RalfJung:remove-const_fn, r=oli-obk
remove const_fn feature gate Fixes #84510 r? `@oli-obk`
2 parents 382f748 + 74918b7 commit 506e75c

31 files changed

+55
-136
lines changed

compiler/rustc_feature/src/active.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -274,9 +274,6 @@ declare_features! (
274274
/// Allows using non lexical lifetimes (RFC 2094).
275275
(active, nll, "1.0.0", Some(43234), None),
276276

277-
/// Allows the definition of `const` functions with some advanced features.
278-
(active, const_fn, "1.2.0", Some(57563), None),
279-
280277
/// Allows associated type defaults.
281278
(active, associated_type_defaults, "1.2.0", Some(29661), None),
282279

compiler/rustc_feature/src/removed.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,9 @@ declare_features! (
136136
(removed, main, "1.53.0", Some(29634), None, None),
137137
(removed, pub_macro_rules, "1.53.0", Some(78855), None,
138138
Some("removed due to being incomplete, in particular it does not work across crates")),
139+
/// Allows the definition of `const` functions with some advanced features.
140+
(removed, const_fn, "1.54.0", Some(57563), None,
141+
Some("split into finer-grained feature gates")),
139142

140143
// -------------------------------------------------------------------------
141144
// feature-group-end: removed features

library/std/src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,6 @@
246246
#![feature(const_cstr_unchecked)]
247247
#![feature(const_fn_floating_point_arithmetic)]
248248
#![feature(const_fn_transmute)]
249-
#![feature(const_fn)]
250249
#![feature(const_fn_fn_ptr_basics)]
251250
#![feature(const_io_structs)]
252251
#![feature(const_ip)]

src/ci/pgo.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ RUSTC_BOOTSTRAP=1 ./build/$PGO_HOST/stage2/bin/rustc --edition=2018 \
1212

1313
# Download and build a single-file stress test benchmark on perf.rust-lang.org.
1414
function pgo_perf_benchmark {
15-
local PERF=9442def56a39d742bf27ebcc3e0614cf117e1bc2
15+
local PERF=1e19fc4c6168d2f7596e512f42f358f245d8f09d
1616
local github_prefix=https://raw.githubusercontent.com/rust-lang/rustc-perf/$PERF
1717
local name=$1
1818
curl -o /tmp/$name.rs $github_prefix/collector/benchmarks/$name/src/lib.rs

src/doc/unstable-book/src/language-features/const-fn.md

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/test/ui/feature-gates/feature-gate-const_fn.rs

Lines changed: 0 additions & 35 deletions
This file was deleted.

src/test/ui/feature-gates/feature-gate-const_fn.stderr

Lines changed: 0 additions & 21 deletions
This file was deleted.

src/test/ui/feature-gates/feature-gate-rustc_const_unstable.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
// Test internal const fn feature gate.
22

3-
#![feature(const_fn)]
4-
53
#[rustc_const_unstable(feature="fzzzzzt")] //~ stability attributes may not be used outside
64
pub const fn bazinga() {}
75

src/test/ui/feature-gates/feature-gate-rustc_const_unstable.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error[E0734]: stability attributes may not be used outside of the standard library
2-
--> $DIR/feature-gate-rustc_const_unstable.rs:5:1
2+
--> $DIR/feature-gate-rustc_const_unstable.rs:3:1
33
|
44
LL | #[rustc_const_unstable(feature="fzzzzzt")]
55
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

src/test/ui/internal/internal-unstable-const.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#![stable(feature = "rust1", since = "1.0.0")]
44

55
#![feature(staged_api)]
6-
#![feature(const_transmute, const_fn)]
6+
#![feature(const_transmute)]
77

88
#[stable(feature = "rust1", since = "1.0.0")]
99
#[rustc_const_stable(feature = "rust1", since = "1.0.0")]

0 commit comments

Comments
 (0)