Feature Request: IndexSet entry APIs
I wonder whether IndexSet::entry is in the roadmap, if yes, I can try to submit PR.
Like the one in hashbrown::HashSet, for IndexSet it will be
impl<T, S> IndexSet<T, S>
where
T: Hash + Eq,
S: BuildHasher,
{
pub fn entry(&mut self, value: T) -> Entry<'_, T, S> { ... }
}
pub enum Entry<'a,T,S> { ... }
Yes, but I'll want to match the eventual API of the standard library HashSet, rust-lang/rust#60896. I don't mind having a draft PR waiting for that, if you're so inclined, but it could be a while before that will be merged.
I presume you're talking about the trait that the Hash macro derives?
If so I would be interested in contributing a PR for this. Seems like an easy fix.
Oh wait never mind disregard my last comment (coding super late)
Although I can add Entry as well, I've implemented it before and its super easy to implement and its very useful
As I mentioned before, the standard library is the blocker to make sure we match a stable API. I agree the implementation is not hard, and if you want you can open that, but it will be blocked for the foreseeable future.