Data.IntMap/IntSet inconsistencies

Ross Paterson ross at soi.city.ac.uk
Mon Nov 2 18:56:01 EST 2009


On Tue, Nov 03, 2009 at 12:43:41AM +0100, Twan van Laarhoven wrote:
> The fact that a function can be written in terms of other things in
> the library is no excuse not to include it. If a program somewhere
> needs to find the smallest key in a map, then it should say so!
> findMin makes the intention of the programmer clear, while toAscList
> does not.

The safe alternative is minViewWithKey.


More information about the Libraries mailing list