Skip to content

Commit 9ebebb2

Browse files
committed
Auto merge of rust-lang#86982 - GuillaumeGomez:rollup-7sbye3c, r=GuillaumeGomez
Rollup of 8 pull requests Successful merges: - rust-lang#84961 (Rework SESSION_GLOBALS API) - rust-lang#86726 (Use diagnostic items instead of lang items for rfc2229 migrations) - rust-lang#86789 (Update BTreeSet::drain_filter documentation) - rust-lang#86838 (Checking that function is const if marked with rustc_const_unstable) - rust-lang#86903 (Fix small headers display) - rust-lang#86913 (Document rustdoc with `--document-private-items`) - rust-lang#86957 (Update .mailmap file) - rust-lang#86971 (mailmap: Add alternative addresses for myself) Failed merges: - rust-lang#86869 (Account for capture kind in auto traits migration) r? `@ghost` `@rustbot` modify labels: rollup
2 parents bfb6e7e + 9b98d91 commit 9ebebb2

File tree

3 files changed

+13
-12
lines changed

3 files changed

+13
-12
lines changed

alloc/src/collections/btree/set.rs

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -940,18 +940,20 @@ impl<T> BTreeSet<T> {
940940
BTreeSet { map: self.map.split_off(key) }
941941
}
942942

943-
/// Creates an iterator which uses a closure to determine if a value should be removed.
943+
/// Creates an iterator that visits all values in ascending order and uses a closure
944+
/// to determine if a value should be removed.
944945
///
945-
/// If the closure returns true, then the value is removed and yielded.
946-
/// If the closure returns false, the value will remain in the list and will not be yielded
947-
/// by the iterator.
946+
/// If the closure returns `true`, the value is removed from the set and yielded. If
947+
/// the closure returns `false`, or panics, the value remains in the set and will
948+
/// not be yielded.
948949
///
949-
/// If the iterator is only partially consumed or not consumed at all, each of the remaining
950-
/// values will still be subjected to the closure and removed and dropped if it returns true.
950+
/// If the iterator is only partially consumed or not consumed at all, each of the
951+
/// remaining values is still subjected to the closure and removed and dropped if it
952+
/// returns `true`.
951953
///
952-
/// It is unspecified how many more values will be subjected to the closure
953-
/// if a panic occurs in the closure, or if a panic occurs while dropping a value, or if the
954-
/// `DrainFilter` itself is leaked.
954+
/// It is unspecified how many more values will be subjected to the closure if a
955+
/// panic occurs in the closure, or if a panic occurs while dropping a value, or if
956+
/// the `DrainFilter` itself is leaked.
955957
///
956958
/// # Examples
957959
///

core/src/marker.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ use crate::hash::Hasher;
3131
/// [ub]: ../../reference/behavior-considered-undefined.html
3232
#[stable(feature = "rust1", since = "1.0.0")]
3333
#[cfg_attr(not(test), rustc_diagnostic_item = "send_trait")]
34-
#[lang = "send"]
3534
#[rustc_on_unimplemented(
3635
message = "`{Self}` cannot be sent between threads safely",
3736
label = "`{Self}` cannot be sent between threads safely"

std/src/panic.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ pub fn panic_any<M: 'static + Any + Send>(msg: M) -> ! {
133133
/// [`AssertUnwindSafe`] wrapper struct can be used to force this trait to be
134134
/// implemented for any closed over variables passed to `catch_unwind`.
135135
#[stable(feature = "catch_unwind", since = "1.9.0")]
136-
#[cfg_attr(not(test), lang = "unwind_safe")]
136+
#[cfg_attr(not(test), rustc_diagnostic_item = "unwind_safe_trait")]
137137
#[rustc_on_unimplemented(
138138
message = "the type `{Self}` may not be safely transferred across an unwind boundary",
139139
label = "`{Self}` may not be safely transferred across an unwind boundary"
@@ -149,7 +149,7 @@ pub auto trait UnwindSafe {}
149149
/// This is a "helper marker trait" used to provide impl blocks for the
150150
/// [`UnwindSafe`] trait, for more information see that documentation.
151151
#[stable(feature = "catch_unwind", since = "1.9.0")]
152-
#[cfg_attr(not(test), lang = "ref_unwind_safe")]
152+
#[cfg_attr(not(test), rustc_diagnostic_item = "ref_unwind_safe_trait")]
153153
#[rustc_on_unimplemented(
154154
message = "the type `{Self}` may contain interior mutability and a reference may not be safely \
155155
transferrable across a catch_unwind boundary",

0 commit comments

Comments
 (0)