Skip to content

Commit 296f938

Browse files
Remove rustc_allow_const_fn_ptr
This was a hack to work around the lack of an escape hatch for the "min `const fn`" checks in const-stable functions. Now that we have co-opted `allow_internal_unstable` for this purpose, we no longer need the bespoke attribute.
1 parent 1082d7a commit 296f938

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

core/src/task/wake.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -129,14 +129,9 @@ impl RawWakerVTable {
129129
/// associated task.
130130
#[rustc_promotable]
131131
#[stable(feature = "futures_api", since = "1.36.0")]
132-
// `rustc_allow_const_fn_ptr` is a hack that should not be used anywhere else
133-
// without first consulting with T-Lang.
134-
//
135-
// FIXME: remove whenever we have a stable way to accept fn pointers from const fn
136-
// (see https://github.com/rust-rfcs/const-eval/issues/19#issuecomment-472799062)
137-
#[rustc_allow_const_fn_ptr]
138132
#[rustc_const_stable(feature = "futures_api", since = "1.36.0")]
139133
#[cfg_attr(not(bootstrap), allow_internal_unstable(const_fn_fn_ptr_basics))]
134+
#[cfg_attr(bootstrap, rustc_allow_const_fn_ptr)]
140135
pub const fn new(
141136
clone: unsafe fn(*const ()) -> RawWaker,
142137
wake: unsafe fn(*const ()),

0 commit comments

Comments
 (0)