Skip to content

Commit 41507ed

Browse files
committed
Auto merge of #76964 - RalfJung:rollup-ybn06fs, r=RalfJung
Rollup of 15 pull requests Successful merges: - #76722 (Test and fix Send and Sync traits of BTreeMap artefacts) - #76766 (Extract some intrinsics out of rustc_codegen_llvm) - #76800 (Don't generate bootstrap usage unless it's needed) - #76809 (simplfy condition in ItemLowerer::with_trait_impl_ref()) - #76815 (Fix wording in mir doc) - #76818 (Don't compile regex at every function call.) - #76821 (Remove redundant nightly features) - #76823 (black_box: silence unused_mut warning when building with cfg(miri)) - #76825 (use `array_windows` instead of `windows` in the compiler) - #76827 (fix array_windows docs) - #76828 (use strip_prefix over starts_with and manual slicing based on pattern length (clippy::manual_strip)) - #76840 (Move to intra doc links in core/src/future) - #76845 (Use intra docs links in core::{ascii, option, str, pattern, hash::map}) - #76853 (Use intra-doc links in library/core/src/task/wake.rs) - #76871 (support panic=abort in Miri) Failed merges: r? `@ghost`
2 parents 5e449b9 + e5be14c commit 41507ed

File tree

51 files changed

+862
-697
lines changed

Some content is hidden

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

51 files changed

+862
-697
lines changed

compiler/rustc_arena/src/lib.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
html_root_url = "https://doc.rust-lang.org/nightly/",
1212
test(no_crate_inject, attr(deny(warnings)))
1313
)]
14-
#![feature(core_intrinsics)]
1514
#![feature(dropck_eyepatch)]
1615
#![feature(new_uninit)]
1716
#![feature(maybe_uninit_slice)]
@@ -24,7 +23,6 @@ use smallvec::SmallVec;
2423
use std::alloc::Layout;
2524
use std::cell::{Cell, RefCell};
2625
use std::cmp;
27-
use std::intrinsics;
2826
use std::marker::{PhantomData, Send};
2927
use std::mem::{self, MaybeUninit};
3028
use std::ptr;
@@ -122,7 +120,7 @@ impl<T> TypedArena<T> {
122120

123121
unsafe {
124122
if mem::size_of::<T>() == 0 {
125-
self.ptr.set(intrinsics::arith_offset(self.ptr.get() as *mut u8, 1) as *mut T);
123+
self.ptr.set((self.ptr.get() as *mut u8).wrapping_offset(1) as *mut T);
126124
let ptr = mem::align_of::<T>() as *mut T;
127125
// Don't drop the object. This `write` is equivalent to `forget`.
128126
ptr::write(ptr, object);

compiler/rustc_ast/src/lib.rs

-4
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,13 @@
55
//! This API is completely unstable and subject to change.
66
77
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/", test(attr(deny(warnings))))]
8-
#![feature(bool_to_option)]
98
#![feature(box_syntax)]
109
#![feature(const_fn)] // For the `transmute` in `P::new`
1110
#![feature(const_panic)]
12-
#![feature(const_fn_transmute)]
1311
#![feature(crate_visibility_modifier)]
1412
#![feature(label_break_value)]
1513
#![feature(nll)]
1614
#![feature(or_patterns)]
17-
#![feature(try_trait)]
18-
#![feature(unicode_internals)]
1915
#![recursion_limit = "256"]
2016

2117
#[macro_use]

compiler/rustc_ast_lowering/src/item.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ pub(super) struct ItemLowerer<'a, 'lowering, 'hir> {
2727
impl ItemLowerer<'_, '_, '_> {
2828
fn with_trait_impl_ref(&mut self, impl_ref: &Option<TraitRef>, f: impl FnOnce(&mut Self)) {
2929
let old = self.lctx.is_in_trait_impl;
30-
self.lctx.is_in_trait_impl = if let &None = impl_ref { false } else { true };
30+
self.lctx.is_in_trait_impl = impl_ref.is_some();
3131
f(self);
3232
self.lctx.is_in_trait_impl = old;
3333
}

0 commit comments

Comments
 (0)