HashMap::entry has the same problem. As I remember there was at least 3 RFC to fix this, but they are not accepted. The current one attempt is raw_entry, based on this idea.
HashMap::entry