Skip to content

Commit 1fc691e

Browse files
committed
Auto merge of #133533 - BoxyUwU:bump-boostrap, r=jieyouxu,Mark-Simulacrum
Bump boostrap compiler to new beta Currently failing due to something about the const stability checks and `panic!`. I'm not sure why though since I wasn't able to see any PRs merged in the past few days that would result in a `cfg(bootstrap)` that shouldn't be removed. cc `@RalfJung` #131349
2 parents d10a682 + 5fa483c commit 1fc691e

Some content is hidden

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

81 files changed

+675
-924
lines changed

compiler/rustc_builtin_macros/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
#![allow(internal_features)]
66
#![allow(rustc::diagnostic_outside_of_impl)]
77
#![allow(rustc::untranslatable_diagnostic)]
8-
#![cfg_attr(not(bootstrap), feature(autodiff))]
98
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
109
#![doc(rust_logo)]
1110
#![feature(assert_matches)]
11+
#![feature(autodiff)]
1212
#![feature(box_patterns)]
1313
#![feature(decl_macro)]
1414
#![feature(if_let_guard)]

compiler/rustc_feature/src/accepted.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ declare_features! (
225225
/// Allows the use of `if let` expressions.
226226
(accepted, if_let, "1.0.0", None),
227227
/// Rescoping temporaries in `if let` to align with Rust 2024.
228-
(accepted, if_let_rescope, "CURRENT_RUSTC_VERSION", Some(124085)),
228+
(accepted, if_let_rescope, "1.84.0", Some(124085)),
229229
/// Allows top level or-patterns (`p | q`) in `if let` and `while let`.
230230
(accepted, if_while_or_patterns, "1.33.0", Some(48215)),
231231
/// Allows lifetime elision in `impl` headers. For example:
@@ -357,7 +357,7 @@ declare_features! (
357357
(accepted, repr_transparent, "1.28.0", Some(43036)),
358358
/// Allows enums like Result<T, E> to be used across FFI, if T's niche value can
359359
/// be used to describe E or vice-versa.
360-
(accepted, result_ffi_guarantees, "CURRENT_RUSTC_VERSION", Some(110503)),
360+
(accepted, result_ffi_guarantees, "1.84.0", Some(110503)),
361361
/// Allows return-position `impl Trait` in traits.
362362
(accepted, return_position_impl_trait_in_trait, "1.75.0", Some(91611)),
363363
/// Allows code like `let x: &'static u32 = &42` to work (RFC 1414).
@@ -367,7 +367,7 @@ declare_features! (
367367
/// Allows `Self` struct constructor (RFC 2302).
368368
(accepted, self_struct_ctor, "1.32.0", Some(51994)),
369369
/// Shortern the tail expression lifetime
370-
(accepted, shorter_tail_lifetimes, "CURRENT_RUSTC_VERSION", Some(123739)),
370+
(accepted, shorter_tail_lifetimes, "1.84.0", Some(123739)),
371371
/// Allows using subslice patterns, `[a, .., b]` and `[a, xs @ .., b]`.
372372
(accepted, slice_patterns, "1.42.0", Some(62254)),
373373
/// Allows use of `&foo[a..b]` as a slicing syntax.

compiler/rustc_feature/src/removed.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ declare_features! (
101101
/// Allows using `#[unsafe_destructor_blind_to_params]` (RFC 1238).
102102
(removed, dropck_parametricity, "1.38.0", Some(28498), None),
103103
/// Uses generic effect parameters for ~const bounds
104-
(removed, effects, "CURRENT_RUSTC_VERSION", Some(102090),
104+
(removed, effects, "1.84.0", Some(102090),
105105
Some("removed, redundant with `#![feature(const_trait_impl)]`")),
106106
/// Allows defining `existential type`s.
107107
(removed, existential_type, "1.38.0", Some(63063),

compiler/rustc_feature/src/unstable.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ declare_features! (
338338
(unstable, riscv_target_feature, "1.45.0", Some(44839)),
339339
(unstable, rtm_target_feature, "1.35.0", Some(44839)),
340340
(unstable, s390x_target_feature, "1.82.0", Some(44839)),
341-
(unstable, sparc_target_feature, "CURRENT_RUSTC_VERSION", Some(132783)),
341+
(unstable, sparc_target_feature, "1.84.0", Some(132783)),
342342
(unstable, sse4a_target_feature, "1.27.0", Some(44839)),
343343
(unstable, tbm_target_feature, "1.27.0", Some(44839)),
344344
(unstable, wasm_target_feature, "1.30.0", Some(44839)),
@@ -538,7 +538,7 @@ declare_features! (
538538
/// Allows `#[marker]` on certain traits allowing overlapping implementations.
539539
(unstable, marker_trait_attr, "1.30.0", Some(29864)),
540540
/// Enables the generic const args MVP (only bare paths, not arbitrary computation).
541-
(incomplete, min_generic_const_args, "CURRENT_RUSTC_VERSION", Some(132980)),
541+
(incomplete, min_generic_const_args, "1.84.0", Some(132980)),
542542
/// A minimal, sound subset of specialization intended to be used by the
543543
/// standard library until the soundness issues with specialization
544544
/// are fixed.

library/alloc/benches/lib.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44
#![feature(iter_next_chunk)]
55
#![feature(repr_simd)]
66
#![feature(slice_partition_dedup)]
7-
#![cfg_attr(bootstrap, feature(strict_provenance))]
8-
#![cfg_attr(not(bootstrap), feature(strict_provenance_lints))]
7+
#![feature(strict_provenance_lints)]
98
#![feature(test)]
109
#![deny(fuzzy_provenance_casts)]
1110

library/alloc/src/boxed.rs

+4-7
Original file line numberDiff line numberDiff line change
@@ -191,9 +191,7 @@ use core::error::{self, Error};
191191
use core::fmt;
192192
use core::future::Future;
193193
use core::hash::{Hash, Hasher};
194-
#[cfg(not(bootstrap))]
195-
use core::marker::PointerLike;
196-
use core::marker::{Tuple, Unsize};
194+
use core::marker::{PointerLike, Tuple, Unsize};
197195
use core::mem::{self, SizedTypeProperties};
198196
use core::ops::{
199197
AsyncFn, AsyncFnMut, AsyncFnOnce, CoerceUnsized, Coroutine, CoroutineState, Deref, DerefMut,
@@ -227,7 +225,7 @@ pub use thin::ThinBox;
227225
#[fundamental]
228226
#[stable(feature = "rust1", since = "1.0.0")]
229227
#[rustc_insignificant_dtor]
230-
#[cfg_attr(not(bootstrap), doc(search_unbox))]
228+
#[doc(search_unbox)]
231229
// The declaration of the `Box` struct must be kept in sync with the
232230
// compiler or ICEs will happen.
233231
pub struct Box<
@@ -1502,7 +1500,7 @@ impl<T: ?Sized, A: Allocator> Box<T, A> {
15021500
/// [`as_ptr`]: Self::as_ptr
15031501
#[unstable(feature = "box_as_ptr", issue = "129090")]
15041502
#[rustc_never_returns_null_ptr]
1505-
#[cfg_attr(not(bootstrap), rustc_as_ptr)]
1503+
#[rustc_as_ptr]
15061504
#[inline]
15071505
pub fn as_mut_ptr(b: &mut Self) -> *mut T {
15081506
// This is a primitive deref, not going through `DerefMut`, and therefore not materializing
@@ -1551,7 +1549,7 @@ impl<T: ?Sized, A: Allocator> Box<T, A> {
15511549
/// [`as_ptr`]: Self::as_ptr
15521550
#[unstable(feature = "box_as_ptr", issue = "129090")]
15531551
#[rustc_never_returns_null_ptr]
1554-
#[cfg_attr(not(bootstrap), rustc_as_ptr)]
1552+
#[rustc_as_ptr]
15551553
#[inline]
15561554
pub fn as_ptr(b: &Self) -> *const T {
15571555
// This is a primitive deref, not going through `DerefMut`, and therefore not materializing
@@ -2134,6 +2132,5 @@ impl<E: Error> Error for Box<E> {
21342132
}
21352133
}
21362134

2137-
#[cfg(not(bootstrap))]
21382135
#[unstable(feature = "pointer_like_trait", issue = "none")]
21392136
impl<T> PointerLike for Box<T> {}

library/alloc/src/boxed/convert.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ impl<T: Clone> From<&[T]> for Box<[T]> {
110110
}
111111

112112
#[cfg(not(no_global_oom_handling))]
113-
#[stable(feature = "box_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
113+
#[stable(feature = "box_from_mut_slice", since = "1.84.0")]
114114
impl<T: Clone> From<&mut [T]> for Box<[T]> {
115115
/// Converts a `&mut [T]` into a `Box<[T]>`
116116
///
@@ -171,7 +171,7 @@ impl From<&str> for Box<str> {
171171
}
172172

173173
#[cfg(not(no_global_oom_handling))]
174-
#[stable(feature = "box_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
174+
#[stable(feature = "box_from_mut_slice", since = "1.84.0")]
175175
impl From<&mut str> for Box<str> {
176176
/// Converts a `&mut str` into a `Box<str>`
177177
///

library/alloc/src/ffi/c_str.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -773,7 +773,7 @@ impl From<&CStr> for Box<CStr> {
773773
}
774774

775775
#[cfg(not(test))]
776-
#[stable(feature = "box_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
776+
#[stable(feature = "box_from_mut_slice", since = "1.84.0")]
777777
impl From<&mut CStr> for Box<CStr> {
778778
/// Converts a `&mut CStr` into a `Box<CStr>`,
779779
/// by copying the contents into a newly allocated [`Box`].
@@ -921,7 +921,7 @@ impl From<&CStr> for Arc<CStr> {
921921
}
922922

923923
#[cfg(target_has_atomic = "ptr")]
924-
#[stable(feature = "shared_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
924+
#[stable(feature = "shared_from_mut_slice", since = "1.84.0")]
925925
impl From<&mut CStr> for Arc<CStr> {
926926
/// Converts a `&mut CStr` into a `Arc<CStr>`,
927927
/// by copying the contents into a newly allocated [`Arc`].
@@ -953,7 +953,7 @@ impl From<&CStr> for Rc<CStr> {
953953
}
954954
}
955955

956-
#[stable(feature = "shared_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
956+
#[stable(feature = "shared_from_mut_slice", since = "1.84.0")]
957957
impl From<&mut CStr> for Rc<CStr> {
958958
/// Converts a `&mut CStr` into a `Rc<CStr>`,
959959
/// by copying the contents into a newly allocated [`Rc`].

library/alloc/src/lib.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -163,8 +163,6 @@
163163
//
164164
// Language features:
165165
// tidy-alphabetical-start
166-
#![cfg_attr(bootstrap, feature(strict_provenance))]
167-
#![cfg_attr(not(bootstrap), feature(strict_provenance_lints))]
168166
#![cfg_attr(not(test), feature(coroutine_trait))]
169167
#![cfg_attr(test, feature(panic_update_hook))]
170168
#![cfg_attr(test, feature(test))]
@@ -188,6 +186,7 @@
188186
#![feature(slice_internals)]
189187
#![feature(staged_api)]
190188
#![feature(stmt_expr_attributes)]
189+
#![feature(strict_provenance_lints)]
191190
#![feature(unboxed_closures)]
192191
#![feature(unsized_fn_params)]
193192
#![feature(with_negative_coherence)]

library/alloc/src/raw_vec.rs

-3
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,6 @@ impl<T> RawVec<T, Global> {
103103
/// `RawVec` with capacity `usize::MAX`. Useful for implementing
104104
/// delayed allocation.
105105
#[must_use]
106-
#[cfg_attr(bootstrap, rustc_const_stable(feature = "raw_vec_internals_const", since = "1.81"))]
107106
pub const fn new() -> Self {
108107
Self::new_in(Global)
109108
}
@@ -179,7 +178,6 @@ impl<T, A: Allocator> RawVec<T, A> {
179178
/// Like `new`, but parameterized over the choice of allocator for
180179
/// the returned `RawVec`.
181180
#[inline]
182-
#[cfg_attr(bootstrap, rustc_const_stable(feature = "raw_vec_internals_const", since = "1.81"))]
183181
pub const fn new_in(alloc: A) -> Self {
184182
Self { inner: RawVecInner::new_in(alloc, align_of::<T>()), _marker: PhantomData }
185183
}
@@ -409,7 +407,6 @@ unsafe impl<#[may_dangle] T, A: Allocator> Drop for RawVec<T, A> {
409407

410408
impl<A: Allocator> RawVecInner<A> {
411409
#[inline]
412-
#[cfg_attr(bootstrap, rustc_const_stable(feature = "raw_vec_internals_const", since = "1.81"))]
413410
const fn new_in(alloc: A, align: usize) -> Self {
414411
let ptr = unsafe { core::mem::transmute(align) };
415412
// `cap: 0` means "unallocated". zero-sized types are ignored.

library/alloc/src/rc.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ fn rc_inner_layout_for_value_layout(layout: Layout) -> Layout {
307307
/// `value.get_mut()`. This avoids conflicts with methods of the inner type `T`.
308308
///
309309
/// [get_mut]: Rc::get_mut
310-
#[cfg_attr(not(bootstrap), doc(search_unbox))]
310+
#[doc(search_unbox)]
311311
#[cfg_attr(not(test), rustc_diagnostic_item = "Rc")]
312312
#[stable(feature = "rust1", since = "1.0.0")]
313313
#[rustc_insignificant_dtor]
@@ -2659,7 +2659,7 @@ impl<T: Clone> From<&[T]> for Rc<[T]> {
26592659
}
26602660

26612661
#[cfg(not(no_global_oom_handling))]
2662-
#[stable(feature = "shared_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
2662+
#[stable(feature = "shared_from_mut_slice", since = "1.84.0")]
26632663
impl<T: Clone> From<&mut [T]> for Rc<[T]> {
26642664
/// Allocates a reference-counted slice and fills it by cloning `v`'s items.
26652665
///
@@ -2698,7 +2698,7 @@ impl From<&str> for Rc<str> {
26982698
}
26992699

27002700
#[cfg(not(no_global_oom_handling))]
2701-
#[stable(feature = "shared_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
2701+
#[stable(feature = "shared_from_mut_slice", since = "1.84.0")]
27022702
impl From<&mut str> for Rc<str> {
27032703
/// Allocates a reference-counted string slice and copies `v` into it.
27042704
///

library/alloc/src/sync.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ macro_rules! acquire {
235235
/// counting in general.
236236
///
237237
/// [rc_examples]: crate::rc#examples
238-
#[cfg_attr(not(bootstrap), doc(search_unbox))]
238+
#[doc(search_unbox)]
239239
#[cfg_attr(not(test), rustc_diagnostic_item = "Arc")]
240240
#[stable(feature = "rust1", since = "1.0.0")]
241241
#[rustc_insignificant_dtor]
@@ -3618,7 +3618,7 @@ impl<T: Clone> From<&[T]> for Arc<[T]> {
36183618
}
36193619

36203620
#[cfg(not(no_global_oom_handling))]
3621-
#[stable(feature = "shared_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
3621+
#[stable(feature = "shared_from_mut_slice", since = "1.84.0")]
36223622
impl<T: Clone> From<&mut [T]> for Arc<[T]> {
36233623
/// Allocates a reference-counted slice and fills it by cloning `v`'s items.
36243624
///
@@ -3657,7 +3657,7 @@ impl From<&str> for Arc<str> {
36573657
}
36583658

36593659
#[cfg(not(no_global_oom_handling))]
3660-
#[stable(feature = "shared_from_mut_slice", since = "CURRENT_RUSTC_VERSION")]
3660+
#[stable(feature = "shared_from_mut_slice", since = "1.84.0")]
36613661
impl From<&mut str> for Arc<str> {
36623662
/// Allocates a reference-counted `str` and copies `v` into it.
36633663
///

library/alloc/src/vec/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1662,7 +1662,7 @@ impl<T, A: Allocator> Vec<T, A> {
16621662
#[stable(feature = "vec_as_ptr", since = "1.37.0")]
16631663
#[rustc_const_unstable(feature = "const_vec_string_slice", issue = "129041")]
16641664
#[rustc_never_returns_null_ptr]
1665-
#[cfg_attr(not(bootstrap), rustc_as_ptr)]
1665+
#[rustc_as_ptr]
16661666
#[inline]
16671667
pub const fn as_ptr(&self) -> *const T {
16681668
// We shadow the slice method of the same name to avoid going through
@@ -1725,7 +1725,7 @@ impl<T, A: Allocator> Vec<T, A> {
17251725
#[stable(feature = "vec_as_ptr", since = "1.37.0")]
17261726
#[rustc_const_unstable(feature = "const_vec_string_slice", issue = "129041")]
17271727
#[rustc_never_returns_null_ptr]
1728-
#[cfg_attr(not(bootstrap), rustc_as_ptr)]
1728+
#[rustc_as_ptr]
17291729
#[inline]
17301730
pub const fn as_mut_ptr(&mut self) -> *mut T {
17311731
// We shadow the slice method of the same name to avoid going through

library/alloc/tests/boxed.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use core::mem::MaybeUninit;
44
use core::ptr::NonNull;
55

66
#[test]
7-
#[cfg_attr(not(bootstrap), expect(dangling_pointers_from_temporaries))]
7+
#[expect(dangling_pointers_from_temporaries)]
88
fn uninitialized_zero_size_box() {
99
assert_eq!(
1010
&*Box::<()>::new_uninit() as *const _,

library/alloc/tests/lib.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,9 @@
3232
#![feature(panic_update_hook)]
3333
#![feature(pointer_is_aligned_to)]
3434
#![feature(thin_box)]
35-
#![cfg_attr(bootstrap, feature(strict_provenance))]
36-
#![cfg_attr(not(bootstrap), feature(strict_provenance_lints))]
3735
#![feature(drain_keep_rest)]
3836
#![feature(local_waker)]
37+
#![feature(strict_provenance_lints)]
3938
#![feature(vec_pop_if)]
4039
#![feature(unique_rc_arc)]
4140
#![feature(macro_metavar_expr_concat)]

library/core/Cargo.toml

-2
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,6 @@ check-cfg = [
4343
'cfg(bootstrap)',
4444
'cfg(no_fp_fmt_parse)',
4545
'cfg(stdarch_intel_sde)',
46-
# #[cfg(bootstrap)] rtems
47-
'cfg(target_os, values("rtems"))',
4846
# core use #[path] imports to portable-simd `core_simd` crate
4947
# and to stdarch `core_arch` crate which messes-up with Cargo list
5048
# of declared features, we therefor expect any feature cfg

library/core/src/alloc/layout.rs

+4-5
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,6 @@ impl Layout {
157157
#[must_use = "this returns the minimum alignment, \
158158
without modifying the layout"]
159159
#[inline]
160-
#[cfg_attr(bootstrap, rustc_allow_const_fn_unstable(ptr_alignment_type))]
161160
pub const fn align(&self) -> usize {
162161
self.align.as_usize()
163162
}
@@ -255,7 +254,7 @@ impl Layout {
255254
/// `align` violates the conditions listed in [`Layout::from_size_align`].
256255
#[stable(feature = "alloc_layout_manipulation", since = "1.44.0")]
257256
#[rustc_const_unstable(feature = "const_alloc_layout", issue = "67521")]
258-
#[cfg_attr(not(bootstrap), rustc_const_stable_indirect)]
257+
#[rustc_const_stable_indirect]
259258
#[inline]
260259
pub const fn align_to(&self, align: usize) -> Result<Self, LayoutError> {
261260
if let Some(align) = Alignment::new(align) {
@@ -331,7 +330,7 @@ impl Layout {
331330
/// to the layout's current size.
332331
#[stable(feature = "alloc_layout_manipulation", since = "1.44.0")]
333332
#[rustc_const_unstable(feature = "const_alloc_layout", issue = "67521")]
334-
#[cfg_attr(not(bootstrap), rustc_const_stable_indirect)]
333+
#[rustc_const_stable_indirect]
335334
#[must_use = "this returns a new `Layout`, \
336335
without modifying the original"]
337336
#[inline]
@@ -431,7 +430,7 @@ impl Layout {
431430
/// ```
432431
#[stable(feature = "alloc_layout_manipulation", since = "1.44.0")]
433432
#[rustc_const_unstable(feature = "const_alloc_layout", issue = "67521")]
434-
#[cfg_attr(not(bootstrap), rustc_const_stable_indirect)]
433+
#[rustc_const_stable_indirect]
435434
#[inline]
436435
pub const fn extend(&self, next: Self) -> Result<(Self, usize), LayoutError> {
437436
let new_align = Alignment::max(self.align, next.align);
@@ -495,7 +494,7 @@ impl Layout {
495494
/// `isize::MAX`, returns `LayoutError`.
496495
#[stable(feature = "alloc_layout_manipulation", since = "1.44.0")]
497496
#[rustc_const_unstable(feature = "const_alloc_layout", issue = "67521")]
498-
#[cfg_attr(not(bootstrap), rustc_const_stable_indirect)]
497+
#[rustc_const_stable_indirect]
499498
#[inline]
500499
pub const fn array<T>(n: usize) -> Result<Self, LayoutError> {
501500
// Reduce the amount of code we need to monomorphize per `T`.

0 commit comments

Comments
 (0)