Skip to content

Commit fb4e1b8

Browse files
committed
span: add a "future" edition
It's hard to implement edition migrations without having a perma-unstable "future" edition to target.
1 parent 4857341 commit fb4e1b8

File tree

2 files changed

+38
-0
lines changed

2 files changed

+38
-0
lines changed

Diff for: core/src/prelude/mod.rs

+23
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,26 @@ pub mod rust_2024 {
7070
#[doc(no_inline)]
7171
pub use crate::future::{Future, IntoFuture};
7272
}
73+
74+
/// The Future version of the core prelude.
75+
///
76+
/// See the [module-level documentation](self) for more.
77+
#[doc(hidden)]
78+
#[unstable(feature = "prelude_future", issue = "none")]
79+
pub mod rust_future {
80+
#[stable(feature = "rust1", since = "1.0.0")]
81+
#[doc(no_inline)]
82+
pub use super::v1::*;
83+
84+
#[stable(feature = "prelude_2021", since = "1.55.0")]
85+
#[doc(no_inline)]
86+
pub use crate::iter::FromIterator;
87+
88+
#[stable(feature = "prelude_2021", since = "1.55.0")]
89+
#[doc(no_inline)]
90+
pub use crate::convert::{TryFrom, TryInto};
91+
92+
#[stable(feature = "prelude_2024", since = "1.85.0")]
93+
#[doc(no_inline)]
94+
pub use crate::future::{Future, IntoFuture};
95+
}

Diff for: std/src/prelude/mod.rs

+15
Original file line numberDiff line numberDiff line change
@@ -160,3 +160,18 @@ pub mod rust_2024 {
160160
#[doc(no_inline)]
161161
pub use core::prelude::rust_2024::*;
162162
}
163+
164+
/// The Future version of the prelude of The Rust Standard Library.
165+
///
166+
/// See the [module-level documentation](self) for more.
167+
#[doc(hidden)]
168+
#[unstable(feature = "prelude_future", issue = "none")]
169+
pub mod rust_future {
170+
#[stable(feature = "rust1", since = "1.0.0")]
171+
#[doc(no_inline)]
172+
pub use super::v1::*;
173+
174+
#[unstable(feature = "prelude_next", issue = "none")]
175+
#[doc(no_inline)]
176+
pub use core::prelude::rust_future::*;
177+
}

0 commit comments

Comments
 (0)