Skip to content

Commit 2a203c5

Browse files
github-actions[bot]Kobzolconnortsui20Aandrebatgross35
authored
Merge subtree update for toolchain nightly-2025-08-20 (#476)
This is an automated PR to merge library subtree updates from 2025-08-19 (rust-lang/rust@9eb4a26) to 2025-08-20 (rust-lang/rust@05f5a58), inclusive. This is a clean merge, no conflicts were detected. **Do not remove or edit the following annotations:** git-subtree-dir: library git-subtree-split: 71d8d81 --------- Signed-off-by: Ayush Singh <[email protected]> Signed-off-by: Jonathan Brouwer <[email protected]> Signed-off-by: Sacha Ayoun <[email protected]> Signed-off-by: Eval EXEC <[email protected]> Signed-off-by: Jens Reidel <[email protected]> Co-authored-by: Jakub Beránek <[email protected]> Co-authored-by: Connor Tsui <[email protected]> Co-authored-by: Aandreba <[email protected]> Co-authored-by: Trevor Gross <[email protected]> Co-authored-by: Stuart Cook <[email protected]> Co-authored-by: Lucas Werkmeister <[email protected]> Co-authored-by: WANG Rui <[email protected]> Co-authored-by: Orson Peters <[email protected]> Co-authored-by: bors <[email protected]> Co-authored-by: Jacob Pratt <[email protected]> Co-authored-by: Ralf Jung <[email protected]> Co-authored-by: Scott McMurray <[email protected]> Co-authored-by: Balt <[email protected]> Co-authored-by: Nurzhan Sakén <[email protected]> Co-authored-by: The rustc-josh-sync Cronjob Bot <[email protected]> Co-authored-by: Tsukasa OI <[email protected]> Co-authored-by: Guillaume Gomez <[email protected]> Co-authored-by: Samuel Tardieu <[email protected]> Co-authored-by: Evgenii Zheltonozhskii <[email protected]> Co-authored-by: Nico Lehmann <[email protected]> Co-authored-by: stifskere <[email protected]> Co-authored-by: Pascal S. de Kloe <[email protected]> Co-authored-by: Folkert de Vries <[email protected]> Co-authored-by: Christopher Hotchkiss <[email protected]> Co-authored-by: Madhav Madhusoodanan <[email protected]> Co-authored-by: Folkert de Vries <[email protected]> Co-authored-by: Kivooeo <[email protected]> Co-authored-by: Ayush Singh <[email protected]> Co-authored-by: Jonathan Brouwer <[email protected]> Co-authored-by: Raoul Strackx <[email protected]> Co-authored-by: Ross MacArthur <[email protected]> Co-authored-by: Paul Murphy <[email protected]> Co-authored-by: Michael Tautschnig <[email protected]> Co-authored-by: Chai T. Rex <[email protected]> Co-authored-by: okaneco <[email protected]> Co-authored-by: The 8472 <[email protected]> Co-authored-by: Josh Triplett <[email protected]> Co-authored-by: Eric Huss <[email protected]> Co-authored-by: Boxy <[email protected]> Co-authored-by: LorrensP-2158466 <[email protected]> Co-authored-by: Karl Meakin <[email protected]> Co-authored-by: Ivan Enderlin <[email protected]> Co-authored-by: Ulrich Stark <[email protected]> Co-authored-by: Shoyu Vanilla <[email protected]> Co-authored-by: Trevor Gross <[email protected]> Co-authored-by: Roger Curley <[email protected]> Co-authored-by: Spxg <[email protected]> Co-authored-by: Chris Denton <[email protected]> Co-authored-by: Ada Alakbarova <[email protected]> Co-authored-by: ltdk <[email protected]> Co-authored-by: Esteban Küber <[email protected]> Co-authored-by: gewitternacht <[email protected]> Co-authored-by: Jakub Stasiak <[email protected]> Co-authored-by: SabrinaJewson <[email protected]> Co-authored-by: Ed Page <[email protected]> Co-authored-by: Ada Alakbarova <[email protected]> Co-authored-by: Mara Bos <[email protected]> Co-authored-by: Sacha Ayoun <[email protected]> Co-authored-by: Tim (Theemathas) Chirananthavat <[email protected]> Co-authored-by: Eval EXEC <[email protected]> Co-authored-by: sayantn <[email protected]> Co-authored-by: Nicholas Nethercote <[email protected]> Co-authored-by: Marcelo Domínguez <[email protected]> Co-authored-by: Jens Reidel <[email protected]> Co-authored-by: Alan Urmancheev <[email protected]> Co-authored-by: binarycat <[email protected]> Co-authored-by: Sebastien Marie <[email protected]> Co-authored-by: 许杰友 Jieyou Xu (Joe) <[email protected]> Co-authored-by: gitbot <git@bot>
1 parent 1231f86 commit 2a203c5

File tree

29 files changed

+478
-262
lines changed

29 files changed

+478
-262
lines changed

library/core/src/fmt/num.rs

Lines changed: 125 additions & 206 deletions
Large diffs are not rendered by default.

library/core/src/lib.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,13 @@ pub mod assert_matches {
228228
pub use crate::macros::{assert_matches, debug_assert_matches};
229229
}
230230

231+
#[unstable(feature = "derive_from", issue = "144889")]
232+
/// Unstable module containing the unstable `From` derive macro.
233+
pub mod from {
234+
#[unstable(feature = "derive_from", issue = "144889")]
235+
pub use crate::macros::builtin::From;
236+
}
237+
231238
// We don't export this through #[macro_export] for now, to avoid breakage.
232239
#[unstable(feature = "autodiff", issue = "124509")]
233240
/// Unstable module containing the unstable `autodiff` macro.

library/core/src/net/ip_addr.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -626,13 +626,13 @@ impl Ipv4Addr {
626626
/// # Examples
627627
///
628628
/// ```
629-
/// #![feature(ip_from)]
630629
/// use std::net::Ipv4Addr;
631630
///
632631
/// let addr = Ipv4Addr::from_octets([13u8, 12u8, 11u8, 10u8]);
633632
/// assert_eq!(Ipv4Addr::new(13, 12, 11, 10), addr);
634633
/// ```
635-
#[unstable(feature = "ip_from", issue = "131360")]
634+
#[stable(feature = "ip_from", since = "CURRENT_RUSTC_VERSION")]
635+
#[rustc_const_stable(feature = "ip_from", since = "CURRENT_RUSTC_VERSION")]
636636
#[must_use]
637637
#[inline]
638638
pub const fn from_octets(octets: [u8; 4]) -> Ipv4Addr {
@@ -1464,7 +1464,6 @@ impl Ipv6Addr {
14641464
/// # Examples
14651465
///
14661466
/// ```
1467-
/// #![feature(ip_from)]
14681467
/// use std::net::Ipv6Addr;
14691468
///
14701469
/// let addr = Ipv6Addr::from_segments([
@@ -1479,7 +1478,8 @@ impl Ipv6Addr {
14791478
/// addr
14801479
/// );
14811480
/// ```
1482-
#[unstable(feature = "ip_from", issue = "131360")]
1481+
#[stable(feature = "ip_from", since = "CURRENT_RUSTC_VERSION")]
1482+
#[rustc_const_stable(feature = "ip_from", since = "CURRENT_RUSTC_VERSION")]
14831483
#[must_use]
14841484
#[inline]
14851485
pub const fn from_segments(segments: [u16; 8]) -> Ipv6Addr {
@@ -2029,7 +2029,6 @@ impl Ipv6Addr {
20292029
/// # Examples
20302030
///
20312031
/// ```
2032-
/// #![feature(ip_from)]
20332032
/// use std::net::Ipv6Addr;
20342033
///
20352034
/// let addr = Ipv6Addr::from_octets([
@@ -2044,7 +2043,8 @@ impl Ipv6Addr {
20442043
/// addr
20452044
/// );
20462045
/// ```
2047-
#[unstable(feature = "ip_from", issue = "131360")]
2046+
#[stable(feature = "ip_from", since = "CURRENT_RUSTC_VERSION")]
2047+
#[rustc_const_stable(feature = "ip_from", since = "CURRENT_RUSTC_VERSION")]
20482048
#[must_use]
20492049
#[inline]
20502050
pub const fn from_octets(octets: [u8; 16]) -> Ipv6Addr {

library/core/src/num/dec2flt/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,8 @@ macro_rules! from_str_float_impl {
124124
/// * '2.5E-10'
125125
/// * '5.'
126126
/// * '.5', or, equivalently, '0.5'
127+
/// * '7'
128+
/// * '007'
127129
/// * 'inf', '-inf', '+infinity', 'NaN'
128130
///
129131
/// Note that alphabetical characters are not case-sensitive.

library/core/src/num/int_macros.rs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2506,8 +2506,7 @@ macro_rules! int_impl {
25062506
///
25072507
/// # Examples
25082508
///
2509-
/// Please note that this example is shared between integer types.
2510-
/// Which explains why `i32` is used here.
2509+
/// Please note that this example is shared among integer types, which is why `i32` is used.
25112510
///
25122511
/// ```
25132512
/// #![feature(bigint_helper_methods)]
@@ -2537,8 +2536,7 @@ macro_rules! int_impl {
25372536
///
25382537
/// # Examples
25392538
///
2540-
/// Please note that this example is shared between integer types.
2541-
/// Which explains why `i32` is used here.
2539+
/// Please note that this example is shared among integer types, which is why `i32` is used.
25422540
///
25432541
/// ```
25442542
/// #![feature(bigint_helper_methods)]
@@ -2575,8 +2573,7 @@ macro_rules! int_impl {
25752573
///
25762574
/// # Examples
25772575
///
2578-
/// Please note that this example is shared between integer types.
2579-
/// Which explains why `i32` is used here.
2576+
/// Please note that this example is shared among integer types, which is why `i32` is used.
25802577
///
25812578
/// ```
25822579
/// #![feature(bigint_helper_methods)]

library/core/src/num/saturating.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -739,8 +739,8 @@ macro_rules! saturating_int_impl {
739739
///
740740
/// # Examples
741741
///
742-
/// Please note that this example is shared between integer types.
743-
/// Which explains why `i16` is used here.
742+
/// Please note that this example is shared among integer types, which is why `i16`
743+
/// is used.
744744
///
745745
/// ```
746746
/// use std::num::Saturating;

library/core/src/num/uint_macros.rs

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2122,8 +2122,7 @@ macro_rules! uint_impl {
21222122
///
21232123
/// # Examples
21242124
///
2125-
/// Please note that this example is shared between integer types.
2126-
/// Which explains why `u8` is used here.
2125+
/// Please note that this example is shared among integer types, which is why `u8` is used.
21272126
///
21282127
/// ```
21292128
/// assert_eq!(10u8.wrapping_mul(12), 120);
@@ -2617,8 +2616,8 @@ macro_rules! uint_impl {
26172616
///
26182617
/// # Examples
26192618
///
2620-
/// Please note that this example is shared between integer types.
2621-
/// Which explains why `u32` is used here.
2619+
/// Please note that this example is shared among integer types, which is why why `u32`
2620+
/// is used.
26222621
///
26232622
/// ```
26242623
/// assert_eq!(5u32.overflowing_mul(2), (10, false));
@@ -2644,8 +2643,7 @@ macro_rules! uint_impl {
26442643
///
26452644
/// # Examples
26462645
///
2647-
/// Please note that this example is shared between integer types.
2648-
/// Which explains why `u32` is used here.
2646+
/// Please note that this example is shared among integer types, which is why `u32` is used.
26492647
///
26502648
/// ```
26512649
/// #![feature(bigint_helper_methods)]
@@ -2675,8 +2673,7 @@ macro_rules! uint_impl {
26752673
///
26762674
/// # Examples
26772675
///
2678-
/// Please note that this example is shared between integer types.
2679-
/// Which explains why `u32` is used here.
2676+
/// Please note that this example is shared among integer types, which is why `u32` is used.
26802677
///
26812678
/// ```
26822679
/// #![feature(bigint_helper_methods)]

library/core/src/num/wrapping.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -775,8 +775,8 @@ macro_rules! wrapping_int_impl {
775775
///
776776
/// # Examples
777777
///
778-
/// Please note that this example is shared between integer types.
779-
/// Which explains why `i16` is used here.
778+
/// Please note that this example is shared among integer types, which is why `i16`
779+
/// is used.
780780
///
781781
/// Basic usage:
782782
///

library/core/src/option.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2095,19 +2095,19 @@ impl<T> Option<&mut T> {
20952095
impl<T, E> Option<Result<T, E>> {
20962096
/// Transposes an `Option` of a [`Result`] into a [`Result`] of an `Option`.
20972097
///
2098-
/// [`None`] will be mapped to <code>[Ok]\([None])</code>.
2099-
/// <code>[Some]\([Ok]\(\_))</code> and <code>[Some]\([Err]\(\_))</code> will be mapped to
2100-
/// <code>[Ok]\([Some]\(\_))</code> and <code>[Err]\(\_)</code>.
2098+
/// <code>[Some]\([Ok]\(\_))</code> is mapped to <code>[Ok]\([Some]\(\_))</code>,
2099+
/// <code>[Some]\([Err]\(\_))</code> is mapped to <code>[Err]\(\_)</code>,
2100+
/// and [`None`] will be mapped to <code>[Ok]\([None])</code>.
21012101
///
21022102
/// # Examples
21032103
///
21042104
/// ```
21052105
/// #[derive(Debug, Eq, PartialEq)]
21062106
/// struct SomeErr;
21072107
///
2108-
/// let x: Result<Option<i32>, SomeErr> = Ok(Some(5));
2109-
/// let y: Option<Result<i32, SomeErr>> = Some(Ok(5));
2110-
/// assert_eq!(x, y.transpose());
2108+
/// let x: Option<Result<i32, SomeErr>> = Some(Ok(5));
2109+
/// let y: Result<Option<i32>, SomeErr> = Ok(Some(5));
2110+
/// assert_eq!(x.transpose(), y);
21112111
/// ```
21122112
#[inline]
21132113
#[stable(feature = "transpose_result", since = "1.33.0")]

library/core/src/prelude/v1.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -117,10 +117,3 @@ pub use crate::macros::builtin::deref;
117117
reason = "`type_alias_impl_trait` has open design concerns"
118118
)]
119119
pub use crate::macros::builtin::define_opaque;
120-
121-
#[unstable(
122-
feature = "derive_from",
123-
issue = "144889",
124-
reason = "`derive(From)` is unstable"
125-
)]
126-
pub use crate::macros::builtin::From;

0 commit comments

Comments
 (0)