Skip to content

Commit ac622da

Browse files
github-actions[bot]pvdrzborsjdonszelmannThe Miri Cronjob Bot
authored
Merge subtree update for toolchain nightly-2025-10-09 (#504)
This is an automated PR to merge library subtree updates from 2025-09-09 (rust-lang/rust@9c27f27) to 2025-10-09 (rust-lang/rust@b6f0945) (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: 7e44c2b --------- Signed-off-by: Petros Angelatos <petrosagg@gmail.com> Signed-off-by: Ayush Singh <ayush@beagleboard.org> Co-authored-by: Christian Poveda <christian.poveda@ferrous-systems.com> Co-authored-by: bors <bors@rust-lang.org> Co-authored-by: Jana Dönszelmann <jonathan@donsz.nl> Co-authored-by: The Miri Cronjob Bot <miri@cron.bot> Co-authored-by: Jacob Pratt <jacob@jhpratt.dev> Co-authored-by: Ralf Jung <post@ralfj.de> Co-authored-by: Maybe Waffle <waffle.lapkin@gmail.com> Co-authored-by: Folkert de Vries <folkert@folkertdev.nl> Co-authored-by: Jo Bates <29763794+jbatez@users.noreply.github.com> Co-authored-by: Zalathar <Zalathar@users.noreply.github.com> Co-authored-by: Tsukasa OI <floss_rust@irq.a4lg.com> Co-authored-by: Laine Taffin Altman <alexanderaltman@me.com> Co-authored-by: Sidney Cammeresi <sac@cheesecake.org> Co-authored-by: Alan Somers <asomers@gmail.com> Co-authored-by: Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> Co-authored-by: Folkert de Vries <flokkievids@gmail.com> Co-authored-by: tiif <pekyuan@gmail.com> Co-authored-by: Nathaniel McCallum <nathaniel@mccallum.life> Co-authored-by: Aapo Alasuutari <aapo.alasuutari@gmail.com> Co-authored-by: Sayantan Chakraborty <142906350+sayantn@users.noreply.github.com> Co-authored-by: Marijn Schouten <mhkbst@gmail.com> Co-authored-by: Joe Birr-Pixton <jpixton@gmail.com> Co-authored-by: Camille Gillot <gillot.camille@gmail.com> Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> Co-authored-by: Alex Crichton <alex@alexcrichton.com> Co-authored-by: Yotam Ofek <yotam.ofek@gmail.com> Co-authored-by: joboet <jonasboettiger@icloud.com> Co-authored-by: Mads Marquart <mads@marquart.dk> Co-authored-by: Thalia Archibald <thalia@archibald.dev> Co-authored-by: tk <49250442+tkr-sh@users.noreply.github.com> Co-authored-by: Ben Kimock <kimockb@gmail.com> Co-authored-by: Jules Bertholet <julesbertholet@quoi.xyz> Co-authored-by: ltdk <usr@ltdk.xyz> Co-authored-by: Petros Angelatos <petrosagg@gmail.com> Co-authored-by: Taiki Endo <te316e89@gmail.com> Co-authored-by: Guillaume Gomez <guillaume1.gomez@gmail.com> Co-authored-by: Peter Lyons Kehl <peter.kehl@gmail.com> Co-authored-by: Ayush Singh <ayush@beagleboard.org> Co-authored-by: sysrex <769991+sysrex@users.noreply.github.com> Co-authored-by: BenjaminBrienen <Benjamin.Brienen@outlook.com> Co-authored-by: Iris Shi <0.0@owo.li> Co-authored-by: Tropical <42101043+Tropix126@users.noreply.github.com> Co-authored-by: Lewis McClelland <lewis@lewismcclelland.me> Co-authored-by: Stepan Koltsov <stepan.koltsov@gmail.com> Co-authored-by: Jeremy Smart <jeremy3141592@gmail.com> Co-authored-by: Adam Harvey <adam@adamharvey.name> Co-authored-by: DimitriiTrater <dima1603040@gmail.com> Co-authored-by: Tim 'Piepmatz' Hesse <git+github@cptpiepmatz.de> Co-authored-by: Vadim Petrochenkov <vadim.petrochenkov@gmail.com> Co-authored-by: Noratrieb <48135649+Noratrieb@users.noreply.github.com> Co-authored-by: Joshua Rayton <joshua.rayton@gmail.com> Co-authored-by: David Carlier <devnexen@gmail.com> Co-authored-by: Mark Rousskov <mark.simulacrum@gmail.com> Co-authored-by: Daniel Verkamp <daniel@drv.nu> Co-authored-by: Jeremy Soller <jackpot51@gmail.com> Co-authored-by: León Orell Valerian Liehr <me@fmease.dev> Co-authored-by: David Tolnay <dtolnay@gmail.com> Co-authored-by: Sebastian Speitel <sebastian.speitel@fem.tu-ilmenau.de> Co-authored-by: cyrgani <ansgar.w.zielke@gmail.com> Co-authored-by: Josh Simmons <josh@nega.tv> Co-authored-by: ivmarkov <ivan.markov@gmail.com> Co-authored-by: Cameron Steffen <cam.steffen94@gmail.com> Co-authored-by: edwloef <edwin.frank.loeffler@gmail.com> Co-authored-by: Fletcher Porter <me@fletcherporter.com> Co-authored-by: EFanZh <efanzh@gmail.com> Co-authored-by: Ada Alakbarova <ada.alakbarova@proton.me> Co-authored-by: Alice Ryhl <aliceryhl@google.com> Co-authored-by: gitbot <git@bot> Co-authored-by: github-merge-queue <118344674+github-merge-queue@users.noreply.github.com> Co-authored-by: Michael Tautschnig <tautschn@amazon.com> Co-authored-by: Bart Jacobs <bart.jacobs@cs.kuleuven.be> Co-authored-by: Nico Lehmann <nico.lehmannm@gmail.com> Co-authored-by: Ranjit Jhala <rjhala@ucsd.edu>
1 parent afb1875 commit ac622da

File tree

367 files changed

+10983
-16340
lines changed

Some content is hidden

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

367 files changed

+10983
-16340
lines changed

.github/workflows/flux.yml

Lines changed: 16 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ on:
88
branches: [main]
99

1010
env:
11-
FIXPOINT_VERSION: "556104ba5508891c357b0bdf819ce706e93d9349"
12-
FLUX_VERSION: "f5e57bec353e2eb3550d2b7ba086462264dfa290"
11+
FLUX_VERSION: "6b080b32801f923bfb590ac48e729de38f829f21"
12+
FIXPOINT_VERSION: "nightly-10-15-2025"
1313

1414
jobs:
1515
check-flux-on-core:
@@ -25,27 +25,22 @@ jobs:
2525
echo ~/.cargo/bin >> $GITHUB_PATH
2626
echo ~/.local/bin >> $GITHUB_PATH
2727
28-
- name: Cache fixpoint
29-
uses: actions/cache@v4
30-
id: cache-fixpoint
31-
with:
32-
path: ~/.local/bin/fixpoint
33-
key: fixpoint-bin-${{ runner.os }}-${{ env.FIXPOINT_VERSION }}
28+
- name: Download and install fixpoint
29+
run: |
30+
set -e
31+
NAME="fixpoint-x86_64-linux-gnu.tar.gz"
32+
URL="https://github.com/ucsd-progsys/liquid-fixpoint/releases/download/${FIXPOINT_VERSION}/${NAME}"
3433
35-
- name: Install Haskell
36-
if: steps.cache-fixpoint.outputs.cache-hit != 'true'
37-
uses: haskell-actions/setup@v2.7.0
38-
with:
39-
enable-stack: true
40-
stack-version: "2.15.7"
34+
echo "Downloading from $URL"
35+
curl -fsSL --retry 3 -o "$NAME" "$URL"
4136
42-
- name: Install fixpoint
43-
if: steps.cache-fixpoint.outputs.cache-hit != 'true'
44-
run: |
45-
git clone https://github.com/ucsd-progsys/liquid-fixpoint.git
46-
cd liquid-fixpoint
47-
git checkout $FIXPOINT_VERSION
48-
stack install --fast --flag liquid-fixpoint:-link-z3-as-a-library
37+
echo "Extracting archive"
38+
tar -xzf "$NAME"
39+
mkdir -p ~/.local/bin
40+
cp fixpoint ~/.local/bin/fixpoint
41+
42+
echo "Cleaning up"
43+
rm -f "$NAME"
4944
5045
- name: Install Z3
5146
uses: cda-tum/setup-z3@v1.6.1

.github/workflows/verifast-negative.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,16 @@ jobs:
3030
- name: Install VeriFast
3131
run: |
3232
cd ~
33-
curl -OL https://github.com/verifast/verifast/releases/download/25.08/verifast-25.08-linux.tar.gz
34-
# https://github.com/verifast/verifast/attestations/10123891
35-
echo '1e40019d6add91bf72141c86f4007f2fe1eef67f453cb7fb8f1f5ab7d31d509f verifast-25.08-linux.tar.gz' | shasum -a 256 -c
36-
tar xf verifast-25.08-linux.tar.gz
33+
curl -OL https://github.com/verifast/verifast/releases/download/25.11/verifast-25.11-linux.tar.gz
34+
# https://github.com/verifast/verifast/attestations/14103492
35+
echo '990c3cadba7cfc9ef9c19d5f1ff039fd746155164fe4a5ec365c625182400f3e verifast-25.11-linux.tar.gz' | shasum -a 256 -c
36+
tar xf verifast-25.11-linux.tar.gz
3737
3838
- name: Install the Rust toolchain used by VeriFast
39-
run: rustup toolchain install nightly-2025-04-09
39+
run: rustup toolchain install nightly-2025-10-09
4040

4141
- name: Run VeriFast Verification
4242
run: |
43-
export PATH=~/verifast-25.08/bin:$PATH
43+
export PATH=~/verifast-25.11/bin:$PATH
4444
cd verifast-proofs
4545
bash check-verifast-proofs-negative.sh

.github/workflows/verifast.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,17 @@ jobs:
2727
- name: Install VeriFast
2828
run: |
2929
cd ~
30-
curl -OL https://github.com/verifast/verifast/releases/download/25.08/verifast-25.08-linux.tar.gz
31-
# https://github.com/verifast/verifast/attestations/10123891
32-
echo '1e40019d6add91bf72141c86f4007f2fe1eef67f453cb7fb8f1f5ab7d31d509f verifast-25.08-linux.tar.gz' | shasum -a 256 -c
33-
tar xf verifast-25.08-linux.tar.gz
30+
curl -OL https://github.com/verifast/verifast/releases/download/25.11/verifast-25.11-linux.tar.gz
31+
# https://github.com/verifast/verifast/attestations/14103492
32+
echo '990c3cadba7cfc9ef9c19d5f1ff039fd746155164fe4a5ec365c625182400f3e verifast-25.11-linux.tar.gz' | shasum -a 256 -c
33+
tar xf verifast-25.11-linux.tar.gz
3434
3535
- name: Install the Rust toolchain used by VeriFast
36-
run: rustup toolchain install nightly-2025-04-09
36+
run: rustup toolchain install nightly-2025-10-09
3737

3838
- name: Run VeriFast Verification
3939
run: |
40-
export PATH=~/verifast-25.08/bin:$PATH
40+
export PATH=~/verifast-25.11/bin:$PATH
4141
cd verifast-proofs
4242
bash check-verifast-proofs.sh
4343

library/Cargo.lock

Lines changed: 12 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

library/alloc/Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@ safety = { path = "../contracts/safety" }
2323
compiler-builtins-mem = ['compiler_builtins/mem']
2424
compiler-builtins-c = ["compiler_builtins/c"]
2525
compiler-builtins-no-f16-f128 = ["compiler_builtins/no-f16-f128"]
26-
# Make panics and failed asserts immediately abort without formatting any message
27-
panic_immediate_abort = ["core/panic_immediate_abort"]
2826
# Choose algorithms that are optimized for binary size instead of runtime performance
2927
optimize_for_size = ["core/optimize_for_size"]
3028

library/alloc/src/alloc.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -408,12 +408,12 @@ pub const fn handle_alloc_error(layout: Layout) -> ! {
408408
}
409409
}
410410

411-
#[cfg(not(feature = "panic_immediate_abort"))]
411+
#[cfg(not(panic = "immediate-abort"))]
412412
{
413413
core::intrinsics::const_eval_select((layout,), ct_error, rt_error)
414414
}
415415

416-
#[cfg(feature = "panic_immediate_abort")]
416+
#[cfg(panic = "immediate-abort")]
417417
ct_error(layout)
418418
}
419419

library/alloc/src/boxed.rs

Lines changed: 35 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -290,8 +290,6 @@ impl<T> Box<T> {
290290
/// # Examples
291291
///
292292
/// ```
293-
/// #![feature(new_zeroed_alloc)]
294-
///
295293
/// let zero = Box::<u32>::new_zeroed();
296294
/// let zero = unsafe { zero.assume_init() };
297295
///
@@ -301,7 +299,7 @@ impl<T> Box<T> {
301299
/// [zeroed]: mem::MaybeUninit::zeroed
302300
#[cfg(not(no_global_oom_handling))]
303301
#[inline]
304-
#[unstable(feature = "new_zeroed_alloc", issue = "129396")]
302+
#[stable(feature = "new_zeroed_alloc", since = "CURRENT_RUSTC_VERSION")]
305303
#[must_use]
306304
pub fn new_zeroed() -> Box<mem::MaybeUninit<T>> {
307305
Self::new_zeroed_in(Global)
@@ -358,7 +356,6 @@ impl<T> Box<T> {
358356
/// # Ok::<(), std::alloc::AllocError>(())
359357
/// ```
360358
#[unstable(feature = "allocator_api", issue = "32838")]
361-
// #[unstable(feature = "new_uninit", issue = "63291")]
362359
#[inline]
363360
pub fn try_new_uninit() -> Result<Box<mem::MaybeUninit<T>>, AllocError> {
364361
Box::try_new_uninit_in(Global)
@@ -384,7 +381,6 @@ impl<T> Box<T> {
384381
///
385382
/// [zeroed]: mem::MaybeUninit::zeroed
386383
#[unstable(feature = "allocator_api", issue = "32838")]
387-
// #[unstable(feature = "new_uninit", issue = "63291")]
388384
#[inline]
389385
pub fn try_new_zeroed() -> Result<Box<mem::MaybeUninit<T>>, AllocError> {
390386
Box::try_new_zeroed_in(Global)
@@ -463,7 +459,6 @@ impl<T, A: Allocator> Box<T, A> {
463459
#[unstable(feature = "allocator_api", issue = "32838")]
464460
#[cfg(not(no_global_oom_handling))]
465461
#[must_use]
466-
// #[unstable(feature = "new_uninit", issue = "63291")]
467462
pub fn new_uninit_in(alloc: A) -> Box<mem::MaybeUninit<T>, A>
468463
where
469464
A: Allocator,
@@ -496,7 +491,6 @@ impl<T, A: Allocator> Box<T, A> {
496491
/// # Ok::<(), std::alloc::AllocError>(())
497492
/// ```
498493
#[unstable(feature = "allocator_api", issue = "32838")]
499-
// #[unstable(feature = "new_uninit", issue = "63291")]
500494
pub fn try_new_uninit_in(alloc: A) -> Result<Box<mem::MaybeUninit<T>, A>, AllocError>
501495
where
502496
A: Allocator,
@@ -532,7 +526,6 @@ impl<T, A: Allocator> Box<T, A> {
532526
/// [zeroed]: mem::MaybeUninit::zeroed
533527
#[unstable(feature = "allocator_api", issue = "32838")]
534528
#[cfg(not(no_global_oom_handling))]
535-
// #[unstable(feature = "new_uninit", issue = "63291")]
536529
#[must_use]
537530
pub fn new_zeroed_in(alloc: A) -> Box<mem::MaybeUninit<T>, A>
538531
where
@@ -570,7 +563,6 @@ impl<T, A: Allocator> Box<T, A> {
570563
///
571564
/// [zeroed]: mem::MaybeUninit::zeroed
572565
#[unstable(feature = "allocator_api", issue = "32838")]
573-
// #[unstable(feature = "new_uninit", issue = "63291")]
574566
pub fn try_new_zeroed_in(alloc: A) -> Result<Box<mem::MaybeUninit<T>, A>, AllocError>
575567
where
576568
A: Allocator,
@@ -627,6 +619,37 @@ impl<T, A: Allocator> Box<T, A> {
627619
pub fn into_inner(boxed: Self) -> T {
628620
*boxed
629621
}
622+
623+
/// Consumes the `Box` without consuming its allocation, returning the wrapped value and a `Box`
624+
/// to the uninitialized memory where the wrapped value used to live.
625+
///
626+
/// This can be used together with [`write`](Box::write) to reuse the allocation for multiple
627+
/// boxed values.
628+
///
629+
/// # Examples
630+
///
631+
/// ```
632+
/// #![feature(box_take)]
633+
///
634+
/// let c = Box::new(5);
635+
///
636+
/// // take the value out of the box
637+
/// let (value, uninit) = Box::take(c);
638+
/// assert_eq!(value, 5);
639+
///
640+
/// // reuse the box for a second value
641+
/// let c = Box::write(uninit, 6);
642+
/// assert_eq!(*c, 6);
643+
/// ```
644+
#[unstable(feature = "box_take", issue = "147212")]
645+
pub fn take(boxed: Self) -> (T, Box<mem::MaybeUninit<T>, A>) {
646+
unsafe {
647+
let (raw, alloc) = Box::into_raw_with_allocator(boxed);
648+
let value = raw.read();
649+
let uninit = Box::from_raw_in(raw.cast::<mem::MaybeUninit<T>>(), alloc);
650+
(value, uninit)
651+
}
652+
}
630653
}
631654

632655
impl<T> Box<[T]> {
@@ -640,7 +663,7 @@ impl<T> Box<[T]> {
640663
/// values[0].write(1);
641664
/// values[1].write(2);
642665
/// values[2].write(3);
643-
/// let values = unsafe {values.assume_init() };
666+
/// let values = unsafe { values.assume_init() };
644667
///
645668
/// assert_eq!(*values, [1, 2, 3])
646669
/// ```
@@ -660,8 +683,6 @@ impl<T> Box<[T]> {
660683
/// # Examples
661684
///
662685
/// ```
663-
/// #![feature(new_zeroed_alloc)]
664-
///
665686
/// let values = Box::<[u32]>::new_zeroed_slice(3);
666687
/// let values = unsafe { values.assume_init() };
667688
///
@@ -670,7 +691,7 @@ impl<T> Box<[T]> {
670691
///
671692
/// [zeroed]: mem::MaybeUninit::zeroed
672693
#[cfg(not(no_global_oom_handling))]
673-
#[unstable(feature = "new_zeroed_alloc", issue = "129396")]
694+
#[stable(feature = "new_zeroed_alloc", since = "CURRENT_RUSTC_VERSION")]
674695
#[must_use]
675696
pub fn new_zeroed_slice(len: usize) -> Box<[mem::MaybeUninit<T>]> {
676697
unsafe { RawVec::with_capacity_zeroed(len).into_box(len) }
@@ -785,7 +806,6 @@ impl<T, A: Allocator> Box<[T], A> {
785806
/// ```
786807
#[cfg(not(no_global_oom_handling))]
787808
#[unstable(feature = "allocator_api", issue = "32838")]
788-
// #[unstable(feature = "new_uninit", issue = "63291")]
789809
#[must_use]
790810
pub fn new_uninit_slice_in(len: usize, alloc: A) -> Box<[mem::MaybeUninit<T>], A> {
791811
unsafe { RawVec::with_capacity_in(len, alloc).into_box(len) }
@@ -813,7 +833,6 @@ impl<T, A: Allocator> Box<[T], A> {
813833
/// [zeroed]: mem::MaybeUninit::zeroed
814834
#[cfg(not(no_global_oom_handling))]
815835
#[unstable(feature = "allocator_api", issue = "32838")]
816-
// #[unstable(feature = "new_uninit", issue = "63291")]
817836
#[must_use]
818837
pub fn new_zeroed_slice_in(len: usize, alloc: A) -> Box<[mem::MaybeUninit<T>], A> {
819838
unsafe { RawVec::with_capacity_zeroed_in(len, alloc).into_box(len) }
@@ -1718,7 +1737,7 @@ impl Default for Box<str> {
17181737
}
17191738

17201739
#[cfg(not(no_global_oom_handling))]
1721-
#[stable(feature = "pin_default_impls", since = "CURRENT_RUSTC_VERSION")]
1740+
#[stable(feature = "pin_default_impls", since = "1.91.0")]
17221741
impl<T> Default for Pin<Box<T>>
17231742
where
17241743
T: ?Sized,

0 commit comments

Comments
 (0)