Skip to content

Commit 9fed91f

Browse files
committed
docs: fix incorrect stability markers on std::{todo, matches}
This regression appeared in 916cfbc. The change is behaving as expected (a non-glob re-export uses the stability marker on the `use` item, not the original one), but this part of the standard library didn't follow it.
1 parent 10fa3c4 commit 9fed91f

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

library/std/src/lib.rs

+8-2
Original file line numberDiff line numberDiff line change
@@ -704,8 +704,14 @@ pub use core::cfg_match;
704704
reason = "`concat_bytes` is not stable enough for use and is subject to change"
705705
)]
706706
pub use core::concat_bytes;
707+
#[stable(feature = "matches_macro", since = "1.42.0")]
708+
#[allow(deprecated, deprecated_in_future)]
709+
pub use core::matches;
707710
#[stable(feature = "core_primitive", since = "1.43.0")]
708711
pub use core::primitive;
712+
#[stable(feature = "todo_macro", since = "1.40.0")]
713+
#[allow(deprecated, deprecated_in_future)]
714+
pub use core::todo;
709715
// Re-export built-in macros defined through core.
710716
#[stable(feature = "builtin_macro_prelude", since = "1.38.0")]
711717
#[allow(deprecated)]
@@ -719,8 +725,8 @@ pub use core::{
719725
#[stable(feature = "rust1", since = "1.0.0")]
720726
#[allow(deprecated, deprecated_in_future)]
721727
pub use core::{
722-
assert_eq, assert_ne, debug_assert, debug_assert_eq, debug_assert_ne, matches, todo, r#try,
723-
unimplemented, unreachable, write, writeln,
728+
assert_eq, assert_ne, debug_assert, debug_assert_eq, debug_assert_ne, r#try, unimplemented,
729+
unreachable, write, writeln,
724730
};
725731

726732
// Include a number of private modules that exist solely to provide

0 commit comments

Comments
 (0)