Containers in the Haskell Platform

Isaac Dupree ml at
Thu Aug 6 16:58:49 EDT 2009

Alexander Dunlap wrote:
> Hi all,
> As we consider what we want to go into the Haskell Platform, I would
> like to seriously discuss the issue of container polymorphism,
> ...
> Thanks for your time in reading this admittedly long message,

Thanks for considering it!

I think these are important issues; however, they're difficult ones that 
have been around for a while, and I don't think we'll be able to solve 
them quickly just because we're making a Haskell Platform.

In some cases issues aren't as bad as they could be.  If a library will 
take Lists of anything, then you can convert your type to a List.  If 
its semantics mean it can only operate on bytes, then it can take 
lazy-ByteStrings (or Strict if it only operates on small things or if it 
can't stream data anyway)... Although it may be efficient, bytestrings 
work badly or not at all for non-byte data.

Incidentally, at some point in the future, a decision may depend on what 
compiler-extensions we're willing to allow into the Platform (I suspect 
that a nice polymorphic solution [with possibly speed problems] 
basically requires Type Functions or equivalent..)


More information about the Libraries mailing list