RFC: Should Data.IntMap.Strict be value-strict in the function arguments or the map itself

Milan Straka fox at ucw.cz
Thu Oct 27 19:35:15 CEST 2011


> > I believe
> >
> > delete undefined Nil
> >
> > does not terminate with current definition, but would terminate
> > if the explicit seq would not be present.
> >
> 
> Good point.
> 
> I think option 2 is bad as it gives users no way to know which functions are
> strict in their value argument without knowing the implementation or us
> documenting every function with the strictness properties. We could do the
> latter but the API would be simpler if we just said that all functions are
> strict in their key and value arguments.

This is even a problem of current API. Although most of the functions
are strict in keys, it is not mentioned at any place in the
documentation.

You are right that option 1 is easily explained and documented.

Cheers,
Milan



More information about the Libraries mailing list