Skip to content

Commit b327f32

Browse files
github-actions[bot]randomPoisonkpreidscottmcmarjunr2
authored
Merge subtree update for toolchain nightly-2025-04-01 (#312)
This is an automated PR to merge library subtree updates from 2025-03-18 (rust-lang/rust@43a2e9d) to 2025-04-01 (rust-lang/rust@0b45675) (inclusive) into main. `git merge` resulted in conflicts, which require manual resolution. Files were commited with merge conflict markers. **Do not remove or edit the following annotations:** git-subtree-dir: library git-subtree-split: c60865a --------- Signed-off-by: xizheyin <[email protected]> Signed-off-by: Sean Cross <[email protected]> Signed-off-by: Jiahao XU <[email protected]> Signed-off-by: Ayush Singh <[email protected]> Co-authored-by: Nicole LeGare <[email protected]> Co-authored-by: Nicole LeGare <[email protected]> Co-authored-by: Nicole L <[email protected]> Co-authored-by: Kevin Reid <[email protected]> Co-authored-by: Scott McMurray <[email protected]> Co-authored-by: Arjun Ramesh <[email protected]> Co-authored-by: bors <[email protected]> Co-authored-by: xizheyin <[email protected]> Co-authored-by: Pavel Grigorenko <[email protected]> Co-authored-by: Oli Scherer <[email protected]> Co-authored-by: Trevor Gross <[email protected]> Co-authored-by: Jakub Beránek <[email protected]> Co-authored-by: Ralf Jung <[email protected]> Co-authored-by: Sean Cross <[email protected]> Co-authored-by: Aurelia Molzer <[email protected]> Co-authored-by: Eric Huss <[email protected]> Co-authored-by: bjorn3 <[email protected]> Co-authored-by: Matthias Krüger <[email protected]> Co-authored-by: beetrees <[email protected]> Co-authored-by: Josh Stone <[email protected]> Co-authored-by: Thalia Archibald <[email protected]> Co-authored-by: Berrysoft <[email protected]> Co-authored-by: Mara Bos <[email protected]> Co-authored-by: Manish Goregaokar <[email protected]> Co-authored-by: ClearLove <[email protected]> Co-authored-by: Thom Chiovoloni <[email protected]> Co-authored-by: Jiahao XU <[email protected]> Co-authored-by: Michael Goulet <[email protected]> Co-authored-by: The Miri Cronjob Bot <[email protected]> Co-authored-by: Jacob Pratt <[email protected]> Co-authored-by: Tobias Bucher <[email protected]> Co-authored-by: León Orell Valerian Liehr <[email protected]> Co-authored-by: Yotam Ofek <[email protected]> Co-authored-by: okaneco <[email protected]> Co-authored-by: 许杰友 Jieyou Xu (Joe) <[email protected]> Co-authored-by: Guillaume Gomez <[email protected]> Co-authored-by: Ayush Singh <[email protected]> Co-authored-by: Noratrieb <[email protected]> Co-authored-by: Marijn Schouten <[email protected]> Co-authored-by: Ibraheem Ahmed <[email protected]> Co-authored-by: Chris Denton <[email protected]> Co-authored-by: Taiki Endo <[email protected]> Co-authored-by: bendn <[email protected]> Co-authored-by: Caleb Zulawski <[email protected]> Co-authored-by: Jana Dönszelmann <[email protected]> Co-authored-by: syvb <[email protected]> Co-authored-by: Sebastian Urban <[email protected]> Co-authored-by: Bardi Harborow <[email protected]> Co-authored-by: moxian <[email protected]> Co-authored-by: Frank King <[email protected]> Co-authored-by: joboet <[email protected]> Co-authored-by: Takayuki Maeda <[email protected]> Co-authored-by: DaniPopes <[email protected]> Co-authored-by: Mads Marquart <[email protected]> Co-authored-by: Christopher Durham <[email protected]> Co-authored-by: Rafael Bachmann <[email protected]> Co-authored-by: Benoît du Garreau <[email protected]> Co-authored-by: Daniel Henry-Mantilla <[email protected]> Co-authored-by: mejrs <[email protected]> Co-authored-by: gitbot <git@bot> Co-authored-by: Michael Tautschnig <[email protected]>
1 parent 9da1baa commit b327f32

File tree

156 files changed

+2930
-2253
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

156 files changed

+2930
-2253
lines changed

library/Cargo.lock

+2-36
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

library/Cargo.toml

-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ members = [
88
]
99

1010
exclude = [
11-
"literal-escaper",
1211
# stdarch has its own Cargo workspace
1312
"stdarch",
1413
"windows_targets"

library/alloc/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ bench = false
1616

1717
[dependencies]
1818
core = { path = "../core", public = true }
19-
compiler_builtins = { version = "=0.1.151", features = ['rustc-dep-of-std'] }
19+
compiler_builtins = { version = "=0.1.152", features = ['rustc-dep-of-std'] }
2020
safety = { path = "../contracts/safety" }
2121

2222
[features]

library/alloc/src/alloc.rs

+8-3
Original file line numberDiff line numberDiff line change
@@ -10,25 +10,28 @@ use core::ptr::{self, NonNull};
1010

1111
unsafe extern "Rust" {
1212
// These are the magic symbols to call the global allocator. rustc generates
13-
// them to call `__rg_alloc` etc. if there is a `#[global_allocator]` attribute
13+
// them to call the global allocator if there is a `#[global_allocator]` attribute
1414
// (the code expanding that attribute macro generates those functions), or to call
1515
// the default implementations in std (`__rdl_alloc` etc. in `library/std/src/alloc.rs`)
1616
// otherwise.
17-
// The rustc fork of LLVM 14 and earlier also special-cases these function names to be able to optimize them
18-
// like `malloc`, `realloc`, and `free`, respectively.
1917
#[rustc_allocator]
2018
#[rustc_nounwind]
19+
#[cfg_attr(not(bootstrap), rustc_std_internal_symbol)]
2120
fn __rust_alloc(size: usize, align: usize) -> *mut u8;
2221
#[rustc_deallocator]
2322
#[rustc_nounwind]
23+
#[cfg_attr(not(bootstrap), rustc_std_internal_symbol)]
2424
fn __rust_dealloc(ptr: *mut u8, size: usize, align: usize);
2525
#[rustc_reallocator]
2626
#[rustc_nounwind]
27+
#[cfg_attr(not(bootstrap), rustc_std_internal_symbol)]
2728
fn __rust_realloc(ptr: *mut u8, old_size: usize, align: usize, new_size: usize) -> *mut u8;
2829
#[rustc_allocator_zeroed]
2930
#[rustc_nounwind]
31+
#[cfg_attr(not(bootstrap), rustc_std_internal_symbol)]
3032
fn __rust_alloc_zeroed(size: usize, align: usize) -> *mut u8;
3133

34+
#[cfg_attr(not(bootstrap), rustc_std_internal_symbol)]
3235
static __rust_no_alloc_shim_is_unstable: u8;
3336
}
3437

@@ -357,6 +360,7 @@ unsafe extern "Rust" {
357360
// This is the magic symbol to call the global alloc error handler. rustc generates
358361
// it to call `__rg_oom` if there is a `#[alloc_error_handler]`, or to call the
359362
// default implementations below (`__rdl_oom`) otherwise.
363+
#[cfg_attr(not(bootstrap), rustc_std_internal_symbol)]
360364
fn __rust_alloc_error_handler(size: usize, align: usize) -> !;
361365
}
362366

@@ -423,6 +427,7 @@ pub mod __alloc_error_handler {
423427
unsafe extern "Rust" {
424428
// This symbol is emitted by rustc next to __rust_alloc_error_handler.
425429
// Its value depends on the -Zoom={panic,abort} compiler option.
430+
#[cfg_attr(not(bootstrap), rustc_std_internal_symbol)]
426431
static __rust_alloc_error_handler_should_panic: u8;
427432
}
428433

library/alloc/src/boxed.rs

+4-8
Original file line numberDiff line numberDiff line change
@@ -1149,9 +1149,8 @@ impl<T: ?Sized, A: Allocator> Box<T, A> {
11491149
///
11501150
/// [memory layout]: self#memory-layout
11511151
#[unstable(feature = "allocator_api", issue = "32838")]
1152-
#[rustc_const_unstable(feature = "const_box", issue = "92521")]
11531152
#[inline]
1154-
pub const unsafe fn from_raw_in(raw: *mut T, alloc: A) -> Self {
1153+
pub unsafe fn from_raw_in(raw: *mut T, alloc: A) -> Self {
11551154
Box(unsafe { Unique::new_unchecked(raw) }, alloc)
11561155
}
11571156

@@ -1203,9 +1202,8 @@ impl<T: ?Sized, A: Allocator> Box<T, A> {
12031202
/// [memory layout]: self#memory-layout
12041203
#[unstable(feature = "allocator_api", issue = "32838")]
12051204
// #[unstable(feature = "box_vec_non_null", reason = "new API", issue = "130364")]
1206-
#[rustc_const_unstable(feature = "const_box", issue = "92521")]
12071205
#[inline]
1208-
pub const unsafe fn from_non_null_in(raw: NonNull<T>, alloc: A) -> Self {
1206+
pub unsafe fn from_non_null_in(raw: NonNull<T>, alloc: A) -> Self {
12091207
// SAFETY: guaranteed by the caller.
12101208
unsafe { Box::from_raw_in(raw.as_ptr(), alloc) }
12111209
}
@@ -1550,9 +1548,8 @@ impl<T: ?Sized, A: Allocator> Box<T, A> {
15501548
/// to call it as `Box::allocator(&b)` instead of `b.allocator()`. This
15511549
/// is so that there is no conflict with a method on the inner type.
15521550
#[unstable(feature = "allocator_api", issue = "32838")]
1553-
#[rustc_const_unstable(feature = "const_box", issue = "92521")]
15541551
#[inline]
1555-
pub const fn allocator(b: &Self) -> &A {
1552+
pub fn allocator(b: &Self) -> &A {
15561553
&b.1
15571554
}
15581555

@@ -1639,8 +1636,7 @@ impl<T: ?Sized, A: Allocator> Box<T, A> {
16391636
/// let bar = Pin::from(foo);
16401637
/// ```
16411638
#[stable(feature = "box_into_pin", since = "1.63.0")]
1642-
#[rustc_const_unstable(feature = "const_box", issue = "92521")]
1643-
pub const fn into_pin(boxed: Self) -> Pin<Self>
1639+
pub fn into_pin(boxed: Self) -> Pin<Self>
16441640
where
16451641
A: 'static,
16461642
{

0 commit comments

Comments
 (0)