Proposal: Value strict versions of containers

Milan Straka fox at ucw.cz
Sun May 22 12:58:08 CEST 2011


> Excerpts from Milan Straka's message of Sun May 22 06:50:07 -0400 2011:
> > - the types Data.IntMap.IntMap, Data.IntMap.Lazy.IntMap and
> >   Data.IntMap.Strict.IntMap should be equal -- so I can use strict
> >   methods on IntMap someone else created with lazy methods. That is
> >   simple in absence of type classes.
> 
> Comment: This would mean you would get no static assurances against
> mixing up a strict IntMap with a lazy IntMap; for all intents and purposes,
> this is equivalent to implementing strict versions of all functions on top
> of a lazy data type.

Exactly.

Do you think we should have different types for static and lazy maps?
It feels odd to me to have these distinguished on type level.
To me it is more about how you want to work with the structure, not the
structure itself.

But maybe others feel differently.

Cheers,
Milan



More information about the Libraries mailing list