Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit ea1066d

Browse files
Bump to latest beta
1 parent 787d323 commit ea1066d

File tree

18 files changed

+416
-434
lines changed

18 files changed

+416
-434
lines changed

library/alloc/src/rc.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1304,7 +1304,7 @@ impl<T: ?Sized, A: Allocator> Rc<T, A> {
13041304
/// assert_eq!(unsafe { &*x_ptr }, "hello");
13051305
/// ```
13061306
#[stable(feature = "rc_raw", since = "1.17.0")]
1307-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
1307+
#[rustc_never_returns_null_ptr]
13081308
pub fn into_raw(this: Self) -> *const T {
13091309
let ptr = Self::as_ptr(&this);
13101310
mem::forget(this);
@@ -1328,7 +1328,7 @@ impl<T: ?Sized, A: Allocator> Rc<T, A> {
13281328
/// assert_eq!(unsafe { &*x_ptr }, "hello");
13291329
/// ```
13301330
#[stable(feature = "weak_into_raw", since = "1.45.0")]
1331-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
1331+
#[rustc_never_returns_null_ptr]
13321332
pub fn as_ptr(this: &Self) -> *const T {
13331333
let ptr: *mut RcBox<T> = NonNull::as_ptr(this.ptr);
13341334

library/alloc/src/sync.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1454,7 +1454,7 @@ impl<T: ?Sized, A: Allocator> Arc<T, A> {
14541454
/// ```
14551455
#[must_use = "losing the pointer will leak memory"]
14561456
#[stable(feature = "rc_raw", since = "1.17.0")]
1457-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
1457+
#[rustc_never_returns_null_ptr]
14581458
pub fn into_raw(this: Self) -> *const T {
14591459
let ptr = Self::as_ptr(&this);
14601460
mem::forget(this);
@@ -1479,7 +1479,7 @@ impl<T: ?Sized, A: Allocator> Arc<T, A> {
14791479
/// ```
14801480
#[must_use]
14811481
#[stable(feature = "rc_as_ptr", since = "1.45.0")]
1482-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
1482+
#[rustc_never_returns_null_ptr]
14831483
pub fn as_ptr(this: &Self) -> *const T {
14841484
let ptr: *mut ArcInner<T> = NonNull::as_ptr(this.ptr);
14851485

library/alloc/src/vec/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1258,7 +1258,7 @@ impl<T, A: Allocator> Vec<T, A> {
12581258
/// [`as_mut_ptr`]: Vec::as_mut_ptr
12591259
/// [`as_ptr`]: Vec::as_ptr
12601260
#[stable(feature = "vec_as_ptr", since = "1.37.0")]
1261-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
1261+
#[rustc_never_returns_null_ptr]
12621262
#[inline]
12631263
pub fn as_ptr(&self) -> *const T {
12641264
// We shadow the slice method of the same name to avoid going through
@@ -1318,7 +1318,7 @@ impl<T, A: Allocator> Vec<T, A> {
13181318
/// [`as_mut_ptr`]: Vec::as_mut_ptr
13191319
/// [`as_ptr`]: Vec::as_ptr
13201320
#[stable(feature = "vec_as_ptr", since = "1.37.0")]
1321-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
1321+
#[rustc_never_returns_null_ptr]
13221322
#[inline]
13231323
pub fn as_mut_ptr(&mut self) -> *mut T {
13241324
// We shadow the slice method of the same name to avoid going through

library/core/src/cell.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -556,7 +556,7 @@ impl<T: ?Sized> Cell<T> {
556556
#[inline]
557557
#[stable(feature = "cell_as_ptr", since = "1.12.0")]
558558
#[rustc_const_stable(feature = "const_cell_as_ptr", since = "1.32.0")]
559-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
559+
#[rustc_never_returns_null_ptr]
560560
pub const fn as_ptr(&self) -> *mut T {
561561
self.value.get()
562562
}
@@ -1112,7 +1112,7 @@ impl<T: ?Sized> RefCell<T> {
11121112
/// ```
11131113
#[inline]
11141114
#[stable(feature = "cell_as_ptr", since = "1.12.0")]
1115-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
1115+
#[rustc_never_returns_null_ptr]
11161116
pub fn as_ptr(&self) -> *mut T {
11171117
self.value.get()
11181118
}
@@ -2107,7 +2107,7 @@ impl<T: ?Sized> UnsafeCell<T> {
21072107
#[inline(always)]
21082108
#[stable(feature = "rust1", since = "1.0.0")]
21092109
#[rustc_const_stable(feature = "const_unsafecell_get", since = "1.32.0")]
2110-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
2110+
#[rustc_never_returns_null_ptr]
21112111
pub const fn get(&self) -> *mut T {
21122112
// We can just cast the pointer from `UnsafeCell<T>` to `T` because of
21132113
// #[repr(transparent)]. This exploits std's special status, there is
@@ -2251,7 +2251,7 @@ impl<T: ?Sized> SyncUnsafeCell<T> {
22512251
/// when casting to `&mut T`, and ensure that there are no mutations
22522252
/// or mutable aliases going on when casting to `&T`
22532253
#[inline]
2254-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
2254+
#[rustc_never_returns_null_ptr]
22552255
pub const fn get(&self) -> *mut T {
22562256
self.value.get()
22572257
}

library/core/src/cmp.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,7 @@ pub trait Eq: PartialEq<Self> {
299299
//
300300
// This should never be implemented by hand.
301301
#[doc(hidden)]
302-
#[cfg_attr(bootstrap, no_coverage)] // rust-lang/rust#84605
303-
#[cfg_attr(not(bootstrap), coverage(off))] //
302+
#[coverage(off)]
304303
#[inline]
305304
#[stable(feature = "rust1", since = "1.0.0")]
306305
fn assert_receiver_is_total_eq(&self) {}
@@ -310,8 +309,7 @@ pub trait Eq: PartialEq<Self> {
310309
#[rustc_builtin_macro]
311310
#[stable(feature = "builtin_macro_prelude", since = "1.38.0")]
312311
#[allow_internal_unstable(core_intrinsics, derive_eq, structural_match)]
313-
#[cfg_attr(bootstrap, allow_internal_unstable(no_coverage))]
314-
#[cfg_attr(not(bootstrap), allow_internal_unstable(coverage_attribute))]
312+
#[allow_internal_unstable(coverage_attribute)]
315313
pub macro Eq($item:item) {
316314
/* compiler built-in */
317315
}

library/core/src/ffi/c_str.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -487,7 +487,7 @@ impl CStr {
487487
#[must_use]
488488
#[stable(feature = "rust1", since = "1.0.0")]
489489
#[rustc_const_stable(feature = "const_str_as_ptr", since = "1.32.0")]
490-
#[cfg_attr(not(bootstrap), rustc_never_returns_null_ptr)]
490+
#[rustc_never_returns_null_ptr]
491491
pub const fn as_ptr(&self) -> *const c_char {
492492
self.inner.as_ptr()
493493
}

library/core/src/intrinsics/mir.rs

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212
//!
1313
//! Typical usage will look like this:
1414
//!
15-
#![cfg_attr(bootstrap, doc = "```rust,ignore")]
16-
#![cfg_attr(not(bootstrap), doc = "```rust")]
15+
//! ```rust
1716
//! #![feature(core_intrinsics, custom_mir)]
1817
//! #![allow(internal_features)]
1918
//!
@@ -63,8 +62,7 @@
6362
//!
6463
//! # Examples
6564
//!
66-
#![cfg_attr(bootstrap, doc = "```rust,ignore")]
67-
#![cfg_attr(not(bootstrap), doc = "```rust")]
65+
//! ```rust
6866
//! #![feature(core_intrinsics, custom_mir)]
6967
//! #![allow(internal_features)]
7068
//!
@@ -106,7 +104,6 @@
106104
//! }
107105
//!
108106
//! #[custom_mir(dialect = "runtime", phase = "optimized")]
109-
#![cfg_attr(bootstrap, doc = "#[cfg(any())]")] // disable the following function in doctests when `bootstrap` is set
110107
//! fn push_and_pop<T>(v: &mut Vec<T>, value: T) {
111108
//! mir!(
112109
//! let _unused;
@@ -319,8 +316,7 @@ define!(
319316
///
320317
/// # Examples
321318
///
322-
#[cfg_attr(bootstrap, doc = "```rust,ignore")]
323-
#[cfg_attr(not(bootstrap), doc = "```rust")]
319+
/// ```rust
324320
/// #![allow(internal_features)]
325321
/// #![feature(custom_mir, core_intrinsics)]
326322
///

library/core/src/lib.rs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,6 @@
110110
//
111111
// Library features:
112112
// tidy-alphabetical-start
113-
#![cfg_attr(bootstrap, feature(no_coverage))] // rust-lang/rust#84605
114-
#![cfg_attr(not(bootstrap), feature(coverage_attribute))] // rust-lang/rust#84605
115113
#![feature(char_indices_offset)]
116114
#![feature(const_align_of_val)]
117115
#![feature(const_align_of_val_raw)]
@@ -173,6 +171,7 @@
173171
#![feature(const_unsafecell_get_mut)]
174172
#![feature(const_waker)]
175173
#![feature(core_panic)]
174+
#![feature(coverage_attribute)]
176175
#![feature(duration_consts_float)]
177176
#![feature(internal_impls_macro)]
178177
#![feature(ip)]
@@ -196,7 +195,6 @@
196195
//
197196
// Language features:
198197
// tidy-alphabetical-start
199-
#![cfg_attr(not(bootstrap), feature(effects))]
200198
#![feature(abi_unadjusted)]
201199
#![feature(adt_const_params)]
202200
#![feature(allow_internal_unsafe)]
@@ -220,6 +218,7 @@
220218
#![feature(doc_cfg)]
221219
#![feature(doc_cfg_hide)]
222220
#![feature(doc_notable_trait)]
221+
#![feature(effects)]
223222
#![feature(exhaustive_patterns)]
224223
#![feature(extern_types)]
225224
#![feature(fundamental)]
@@ -412,13 +411,13 @@ pub mod primitive;
412411
dead_code,
413412
unused_imports,
414413
unsafe_op_in_unsafe_fn,
415-
ambiguous_glob_reexports
414+
ambiguous_glob_reexports,
415+
deprecated_in_future
416416
)]
417417
#[allow(rustdoc::bare_urls)]
418418
// FIXME: This annotation should be moved into rust-lang/stdarch after clashing_extern_declarations is
419419
// merged. It currently cannot because bootstrap fails as the lint hasn't been defined yet.
420420
#[allow(clashing_extern_declarations)]
421-
#[cfg_attr(bootstrap, allow(deprecated_in_future))]
422421
#[unstable(feature = "stdsimd", issue = "48556")]
423422
mod core_arch;
424423

library/core/src/num/saturating.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,7 @@ use crate::ops::{Sub, SubAssign};
3535
#[derive(PartialEq, Eq, PartialOrd, Ord, Clone, Copy, Default, Hash)]
3636
#[repr(transparent)]
3737
#[rustc_diagnostic_item = "Saturating"]
38-
pub struct Saturating<T>(
39-
#[stable(feature = "saturating_int_impl", since = "1.74.0")] pub T,
40-
);
38+
pub struct Saturating<T>(#[stable(feature = "saturating_int_impl", since = "1.74.0")] pub T);
4139

4240
#[stable(feature = "saturating_int_impl", since = "1.74.0")]
4341
impl<T: fmt::Debug> fmt::Debug for Saturating<T> {

library/core/src/panicking.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,6 @@ fn panic_cannot_unwind() -> ! {
229229
/// pass to `panic_nounwind`.
230230
/// This function is called directly by the codegen backend, and must not have
231231
/// any extra arguments (including those synthesized by track_caller).
232-
#[cfg(not(bootstrap))]
233232
#[cfg_attr(not(feature = "panic_immediate_abort"), inline(never), cold)]
234233
#[cfg_attr(feature = "panic_immediate_abort", inline)]
235234
#[lang = "panic_in_cleanup"] // needed by codegen for panic in nounwind function

0 commit comments

Comments
 (0)