Skip to content

Commit 45ed9e9

Browse files
github-actions[bot]tgross35folkertdevfmeasefu5ha
authored
Merge subtree update for toolchain nightly-2025-07-02 (#407)
This is an automated PR to merge library subtree updates from 2025-06-17 (rust-lang/rust@45acf54) to 2025-07-02 (rust-lang/rust@71e4c00) (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: 46c01c8 --------- Signed-off-by: xizheyin <xizheyin@smail.nju.edu.cn> Co-authored-by: Trevor Gross <tmgross@umich.edu> Co-authored-by: Folkert de Vries <folkert@folkertdev.nl> Co-authored-by: León Orell Valerian Liehr <me@fmease.dev> Co-authored-by: Gray Olson <gray@grayolson.com> Co-authored-by: Pascal S. de Kloe <pascal@quies.net> Co-authored-by: David Carlier <devnexen@gmail.com> Co-authored-by: bors <bors@rust-lang.org> Co-authored-by: Shun Sakai <sorairolake@protonmail.ch> Co-authored-by: Deven T. Corzine <deven@ties.org> Co-authored-by: Amanieu d'Antras <amanieu@gmail.com> Co-authored-by: Boxy <rust@boxyuwu.dev> Co-authored-by: Mara Bos <m-ou.se@m-ou.se> Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Jeremy Smart <jeremy3141592@gmail.com> Co-authored-by: Urgau <urgau@numericable.fr> Co-authored-by: Jakub Beránek <berykubik@gmail.com> Co-authored-by: xizheyin <xizheyin@smail.nju.edu.cn> Co-authored-by: Ralf Jung <post@ralfj.de> Co-authored-by: Tamir Duberstein <tamird@gmail.com> Co-authored-by: Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> Co-authored-by: mejrs <59372212+mejrs@users.noreply.github.com> Co-authored-by: qinghon <wushengshijie@outlook.com> Co-authored-by: Chris Denton <chris@chrisdenton.dev> Co-authored-by: Sasha Pourcelot <sasha.pourcelot@protonmail.com> Co-authored-by: Soveu <marx.tomasz@gmail.com> Co-authored-by: David Tolnay <dtolnay@gmail.com> Co-authored-by: Jubilee <workingjubilee@gmail.com> Co-authored-by: Mu001999 <mu001999@outlook.com> Co-authored-by: bjorn3 <17426603+bjorn3@users.noreply.github.com> Co-authored-by: sayantn <sayantn05@gmail.com> Co-authored-by: Christopher Berner <me@cberner.com> Co-authored-by: Markus Reiter <me@reitermark.us> Co-authored-by: The 8472 <git@infinite-source.de> Co-authored-by: 王宇逸 <Strawberry_Str@hotmail.com> Co-authored-by: Marijn Schouten <mhkbst@gmail.com> Co-authored-by: Michał Łowicki <mlowicki@gmail.com> Co-authored-by: Yotam Ofek <yotam.ofek@gmail.com> Co-authored-by: Guillaume Gomez <guillaume1.gomez@gmail.com> Co-authored-by: David Wood <david.wood2@arm.com> Co-authored-by: Neal <nealsid@users.noreply.github.com> Co-authored-by: Tomoaki Kobayashi <tomoaki.kobayashi.t3@alumni.tohoku.ac.jp> Co-authored-by: Daniel Paoliello <danpao@microsoft.com> Co-authored-by: Marijn Schouten <hkBst@users.noreply.github.com> Co-authored-by: Benoît du Garreau <benoit@dugarreau.fr> Co-authored-by: Aniket Mishra <143333884+satiscugcat@users.noreply.github.com> Co-authored-by: satiscugcat <23110026@iitgn.ac.in> Co-authored-by: Jacob Pratt <jacob@jhpratt.dev> Co-authored-by: Urgau <3616612+Urgau@users.noreply.github.com> Co-authored-by: Zachary S <zasample18+github@gmail.com> Co-authored-by: Trevor Gross <t.gross35@gmail.com> Co-authored-by: Tim (Theemathas) Chirananthavat <theemathas@gmail.com> Co-authored-by: Alice Ryhl <aliceryhl@google.com> Co-authored-by: Kornel <kornel@geekhood.net> Co-authored-by: Daniel Bloom <7810950-Daniel.Aaron.Bloom@users.noreply.gitlab.com> Co-authored-by: Ed Page <eopage@gmail.com> Co-authored-by: The Miri Cronjob Bot <miri@cron.bot> Co-authored-by: Chai T. Rex <ChaiTRex@users.noreply.github.com> Co-authored-by: Valdemar Erk <valdemar@erk.dev> Co-authored-by: Samuel Tardieu <sam@rfc1149.net> Co-authored-by: binarycat <binarycat@envs.net> Co-authored-by: Tshepang Mbambo <hopsi@tuta.io> Co-authored-by: Laine Taffin Altman <alexanderaltman@me.com> Co-authored-by: Oli Scherer <github333195615777966@oli-obk.de> Co-authored-by: MetaNova <adam.magnum@gmail.com> Co-authored-by: Kurt Heiritz (pseudo) <saarthkarkera@gmail.com> Co-authored-by: krikera <prafulrai522@gmail.com> Co-authored-by: Pavel Grigorenko <GrigorenkoPV@ya.ru> Co-authored-by: Michael Goulet <michael@errs.io> Co-authored-by: Bastian Kersting <bkersting@google.com> Co-authored-by: Deadbeef <ent3rm4n@gmail.com> Co-authored-by: Cheng Xu <git@xuc.me> Co-authored-by: наб <nabijaczleweli@nabijaczleweli.xyz> Co-authored-by: kilavvy <140459108+kilavvy@users.noreply.github.com> Co-authored-by: zachs18 <8355914+zachs18@users.noreply.github.com> Co-authored-by: dianqk <dianqk@dianqk.net> Co-authored-by: gitbot <git@bot> Co-authored-by: Michael Tautschnig <tautschn@amazon.com>
1 parent 8f55686 commit 45ed9e9

File tree

437 files changed

+733805
-2724
lines changed

Some content is hidden

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

437 files changed

+733805
-2724
lines changed

.github/workflows/goto-transcoder.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,6 @@ jobs:
2727
uses: actions/checkout@v4
2828
with:
2929
submodules: true
30-
- name: Apply stdarch patch
31-
run: cd library/stdarch && patch -p1 < ../../stdarch.patch
3230

3331
# Step 2: Generate contracts programs
3432
- name: Generate contracts

.github/workflows/kani-metrics.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,7 @@ jobs:
2525
uses: actions/checkout@v4
2626
with:
2727
submodules: true
28-
- name: Apply stdarch patch
29-
run: cd library/stdarch && patch -p1 < ../../stdarch.patch
30-
28+
3129
# The Kani metrics collection uses a Python script (kani_std_analysis.py), so make sure Python is installed
3230
- name: Set up Python
3331
uses: actions/setup-python@v4

.github/workflows/kani.yml

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,7 @@ jobs:
5151
with:
5252
path: head
5353
submodules: true
54-
- name: Apply stdarch patch
55-
run: cd head/library/stdarch && patch -p1 < ../../stdarch.patch
56-
54+
5755
# Step 2: Install jq
5856
- name: Install jq
5957
if: matrix.os == 'ubuntu-latest'
@@ -90,8 +88,6 @@ jobs:
9088
uses: actions/checkout@v4
9189
with:
9290
submodules: true
93-
- name: Apply stdarch patch
94-
run: cd library/stdarch && patch -p1 < ../../stdarch.patch
9591

9692
# Step 2: Run Kani autoharness on the std library for selected functions.
9793
# Uses "--include-pattern" to make sure we do not try to run across all
@@ -102,8 +98,6 @@ jobs:
10298
# - We use >::disjoint_bitor (and >::unchecked_disjoint_bitor) as pattern
10399
# as whitespace is not supported, cf.
104100
# https://github.com/model-checking/kani/issues/4046
105-
# - core_arch::x86::__m128d::as_f64x2 is just one example of hundreds of
106-
# core_arch::x86:: functions that are known to verify successfully.
107101
- name: Run Kani Verification
108102
run: |
109103
scripts/run-kani.sh --run autoharness --kani-args \
@@ -113,7 +107,6 @@ jobs:
113107
--include-pattern alloc::layout::Layout::from_size_align \
114108
--include-pattern ascii::ascii_char::AsciiChar::from_u8 \
115109
--include-pattern char::convert::from_u32_unchecked \
116-
--include-pattern core_arch::x86::__m128d::as_f64x2 \
117110
--include-pattern "num::nonzero::NonZero::<i8>::count_ones" \
118111
--include-pattern "num::nonzero::NonZero::<i16>::count_ones" \
119112
--include-pattern "num::nonzero::NonZero::<i32>::count_ones" \
@@ -295,8 +288,6 @@ jobs:
295288
with:
296289
path: head
297290
submodules: true
298-
- name: Apply stdarch patch
299-
run: cd head/library/stdarch && patch -p1 < ../../stdarch.patch
300291

301292
# Step 2: Run list on the std library
302293
- name: Run Kani List
@@ -329,8 +320,6 @@ jobs:
329320
uses: actions/checkout@v4
330321
with:
331322
submodules: true
332-
- name: Apply stdarch patch
333-
run: cd library/stdarch && patch -p1 < ../../stdarch.patch
334323

335324
# Step 2: Run autoharness analyzer on the std library
336325
- name: Run Autoharness Analyzer

library/Cargo.lock

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

library/Cargo.toml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
cargo-features = ["profile-rustflags"]
2+
13
[workspace]
24
resolver = "1"
35
members = [
@@ -44,9 +46,16 @@ object.debug = 0
4446
rustc-demangle.debug = 0
4547
rustc-demangle.opt-level = "s"
4648

49+
# panic_abort must always be compiled with panic=abort, even when the rest of the
50+
# sysroot is panic=unwind.
51+
[profile.dev.package.panic_abort]
52+
rustflags = ["-Cpanic=abort"]
53+
54+
[profile.release.package.panic_abort]
55+
rustflags = ["-Cpanic=abort"]
56+
4757
[patch.crates-io]
48-
# See comments in `library/rustc-std-workspace-core/README.md` for what's going on
49-
# here
58+
# See comments in `library/rustc-std-workspace-core/README.md` for what's going on here
5059
rustc-std-workspace-core = { path = 'rustc-std-workspace-core' }
5160
rustc-std-workspace-alloc = { path = 'rustc-std-workspace-alloc' }
5261
rustc-std-workspace-std = { path = 'rustc-std-workspace-std' }

library/alloc/src/alloc.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,9 @@ unsafe extern "Rust" {
3131
#[rustc_std_internal_symbol]
3232
fn __rust_alloc_zeroed(size: usize, align: usize) -> *mut u8;
3333

34+
#[rustc_nounwind]
3435
#[rustc_std_internal_symbol]
35-
static __rust_no_alloc_shim_is_unstable: u8;
36+
fn __rust_no_alloc_shim_is_unstable_v2();
3637
}
3738

3839
/// The global memory allocator.
@@ -88,7 +89,7 @@ pub unsafe fn alloc(layout: Layout) -> *mut u8 {
8889
unsafe {
8990
// Make sure we don't accidentally allow omitting the allocator shim in
9091
// stable code until it is actually stabilized.
91-
core::ptr::read_volatile(&__rust_no_alloc_shim_is_unstable);
92+
__rust_no_alloc_shim_is_unstable_v2();
9293

9394
__rust_alloc(layout.size(), layout.align())
9495
}
@@ -171,7 +172,7 @@ pub unsafe fn alloc_zeroed(layout: Layout) -> *mut u8 {
171172
unsafe {
172173
// Make sure we don't accidentally allow omitting the allocator shim in
173174
// stable code until it is actually stabilized.
174-
core::ptr::read_volatile(&__rust_no_alloc_shim_is_unstable);
175+
__rust_no_alloc_shim_is_unstable_v2();
175176

176177
__rust_alloc_zeroed(layout.size(), layout.align())
177178
}

library/alloc/src/collections/btree/set.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1517,9 +1517,7 @@ impl<T: Ord, const N: usize> From<[T; N]> for BTreeSet<T> {
15171517

15181518
// use stable sort to preserve the insertion order.
15191519
arr.sort();
1520-
let iter = IntoIterator::into_iter(arr).map(|k| (k, SetValZST::default()));
1521-
let map = BTreeMap::bulk_build_from_sorted_iter(iter, Global);
1522-
BTreeSet { map }
1520+
BTreeSet::from_sorted_iter(IntoIterator::into_iter(arr), Global)
15231521
}
15241522
}
15251523

0 commit comments

Comments
 (0)