diff options
| author | tosti007 <git@brianjanssen.nl> | 2023-03-29 15:10:35 +0200 |
|---|---|---|
| committer | tosti007 <git@brianjanssen.nl> | 2023-03-29 15:10:35 +0200 |
| commit | 6b98dcc743bd04bc2300655c4e800e6b1dd6f911 (patch) | |
| tree | 193fb5a505ce3dd237e93d2952b49acbf0d6776a | |
| parent | cf32b9de1e8f66526c36ad2927458558d2e81093 (diff) | |
| download | rust-6b98dcc743bd04bc2300655c4e800e6b1dd6f911.tar.gz rust-6b98dcc743bd04bc2300655c4e800e6b1dd6f911.zip | |
Use with_capacity_and_hasher instead of using base
| -rw-r--r-- | library/std/src/collections/hash/set.rs | 2 |
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 837a18bff60..d46bc288ebe 100644 --- a/library/std/src/collections/hash/set.rs +++ b/library/std/src/collections/hash/set.rs @@ -143,7 +143,7 @@ impl<T> HashSet<T, RandomState> { #[must_use] #[stable(feature = "rust1", since = "1.0.0")] pub fn with_capacity(capacity: usize) -> HashSet<T, RandomState> { - HashSet { base: base::HashSet::with_capacity_and_hasher(capacity, Default::default()) } + HashSet::with_capacity_and_hasher(capacity, Default::default()) } } |
