Lookup variant for IntMap

Simon Jakobi simon.jakobi at googlemail.com
Mon Aug 16 18:28:16 UTC 2021


Am Mo., 16. Aug. 2021 um 17:06 Uhr schrieb Jan-Willem Maessen
<jmaessen at alum.mit.edu>:
>
> Reading the issue and the benchmarks, it seems like the right call here might be to make the "throws error" version the one that defers the failure check, and to use a similar algorithm for update (which must search to the leaf in any case).

update can terminate fast too. See the nomatch case in updateWithKey:
https://hackage.haskell.org/package/containers-0.6.5.1/docs/src/Data.IntMap.Internal.html#update


More information about the Libraries mailing list