fix typo in hashmap and hashset try_reserve method

This commit is contained in:
joseLuís 2022-10-29 10:49:53 +02:00
parent 33b55ac39f
commit 4b353132f5
2 changed files with 2 additions and 2 deletions

View File

@ -759,7 +759,7 @@ where
/// Tries to reserve capacity for at least `additional` more elements to be inserted
/// in the `HashMap`. The collection may reserve more space to speculatively
/// avoid frequent reallocations. After calling `reserve`,
/// avoid frequent reallocations. After calling `try_reserve`,
/// capacity will be greater than or equal to `self.len() + additional` if
/// it returns `Ok(())`.
/// Does nothing if capacity is already sufficient.

View File

@ -462,7 +462,7 @@ where
/// Tries to reserve capacity for at least `additional` more elements to be inserted
/// in the `HashSet`. The collection may reserve more space to speculatively
/// avoid frequent reallocations. After calling `reserve`,
/// avoid frequent reallocations. After calling `try_reserve`,
/// capacity will be greater than or equal to `self.len() + additional` if
/// it returns `Ok(())`.
/// Does nothing if capacity is already sufficient.