Small cleanups in HashMap based off of new rust features.

r? @Gankro @pczarn
minor concern that we're losing some semantics here