about summary refs log tree commit diff
path: root/library/std/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-01-07 22:42:39 +0000
committerbors <bors@rust-lang.org>2023-01-07 22:42:39 +0000
commite5d46a5bdac3f19793297914d4ada432024fbe95 (patch)
tree8906e54cb1653ccd0127f88b4979fb806f61aa9f /library/std/src
parentee0412d1ef81efcfabe7f66cd21476ca85d618b1 (diff)
parent3076f269888008c6c47d5572e629a3e390597c97 (diff)
downloadrust-e5d46a5bdac3f19793297914d4ada432024fbe95.tar.gz
rust-e5d46a5bdac3f19793297914d4ada432024fbe95.zip
Auto merge of #106573 - matthiaskrgr:rollup-zkgfsta, r=matthiaskrgr
Rollup of 10 pull requests

Successful merges:

 - #101936 (Migrating rustc_infer to session diagnostics (part 3))
 - #104081 (PhantomData layout guarantees)
 - #104543 (Migrate `codegen_ssa` to diagnostics structs - [Part 3])
 - #105128 (Add O(1) `Vec -> VecDeque` conversion guarantee)
 - #105517 (Fix process-panic-after-fork.rs to pass on newer versions of Android.)
 - #105859 (Point out span where we could introduce higher-ranked lifetime)
 - #106509 (Detect closures assigned to binding in block)
 - #106553 (docs: make `HashSet::retain` doctest more clear)
 - #106556 (rustdoc: remove no-op mobile CSS `.content { margin-left: 0 }`)
 - #106564 (Change to immutable borrow when cloning element of RepeatN)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'library/std/src')
-rw-r--r--library/std/src/collections/hash/set.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/std/src/collections/hash/set.rs b/library/std/src/collections/hash/set.rs
index cee884145c7..b59f89d321c 100644
--- a/library/std/src/collections/hash/set.rs
+++ b/library/std/src/collections/hash/set.rs
@@ -317,7 +317,7 @@ impl<T, S> HashSet<T, S> {
     ///
     /// let mut set = HashSet::from([1, 2, 3, 4, 5, 6]);
     /// set.retain(|&k| k % 2 == 0);
-    /// assert_eq!(set.len(), 3);
+    /// assert_eq!(set, HashSet::from([2, 4, 6]));
     /// ```
     ///
     /// # Performance