You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by GitBox <gi...@apache.org> on 2022/11/23 13:48:50 UTC

[GitHub] [lucene] jpountz commented on pull request #11942: Ensure collections are properly sized on creation

jpountz commented on PR #11942:
URL: https://github.com/apache/lucene/pull/11942#issuecomment-1325093360

   In most these cases I would guess that getting the initial size right is not as important as avoiding largely oversizing the hash map, so it's not really an issue that callers are passing a size rather than a capacity to the `HashMap` constructor. Thanks for pointing out the upcoming `HashMap.newHashMap` in JDK 19, it makes me feel better about the method you introduced, can you add a comment that it should get removed when Lucene moves to JDK 19+ as a minimum required version?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org