[FR] Mutable access to stateful hashers and comparators
- Dominant language
- C++
- Stars
- 92
- Forks
- 88
- PR merge metrics
- No merged PRs in 30d
Description
(like the implementation table_core class template provides)
I have an exotic use case where the state of the two subject objects references an external 'master' object which can potentially get moved around in memory/has an unstable reference (say as if stored in a std::vector) yet when I need to use the unordered container in question I know for certain that the 'master' object is 'pinned' - and would like to simply then update the reference stored in the hasher...
Yes - this opens up the can of worms of enabling the user the change the hasher in such a way that it potentially changes the hashes it returns - but this is already possible just not as easily (exactly by storing references in hashers) - so simply demand that hashes and comparators be [[ gnu::const ]] or else UB...?
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.