Lookup variant for IntMap
callan.mcgill at gmail.com
Mon Aug 16 12:08:31 UTC 2021
I recently noticed that lookup for IntMap favours searches that can
fast-fail - if instead we are in a situation where lookups are mostly
successful, then this can be wasteful (see this issue for details:
https://github.com/haskell/containers/issues/794). Since both versions are
useful, it would be best to offer users both variants.
I wondered if people on this list had any suggestions for a name for the
new function? David Feuer also wondered which of these two behaviours
should be the default. My inclination is for it to be the current version
which fails faster (this also guarantees no unfortunate regressions) but it
would be useful to run more substantial real-world benchmarks to figure
that out (if anyone has any suggestions then do let me know).
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Libraries