-
Notifications
You must be signed in to change notification settings - Fork 291
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #355 - TennyZhuang:make-with-hasher-in-const, r=Amanieu
make with_hasher_in const (consistent with with_hasher) I found that the following four methods have additional comments about their allocation: * HashMap::with_hasher * HashMap::with_hasher_in * HashSet::with_hasher * HashSet::with_hasher_in There is no reason to make such a difference; in this PR, I make them consistent as the following behavior: * All methods clarify that they will not allocate memory before the first insertion * All methods are marked as const function. We also bump the MSRV to 1.61.0 for the const_fn_trait_bound feature. Currently, 1.64.0 has been released, and I guess it's acceptable to break the 1.61.0 users. Signed-off-by: TennyZhuang <[email protected]>
- Loading branch information
Showing
5 changed files
with
14 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters