Heirarchical name space allocation /Trees

Christian Maeder maeder at tzi.de
Wed Mar 31 16:42:29 EST 2004

Ross Paterson wrote:
> I'd like to suggest (again) treating sequences differently from the rest,
> and that they should be defined by a class:
> * the class fits within Haskell 98, because sequences have only one
>   parameter, and it's unconstrained.
> * polymorphism is likely to be more useful with sequences because of
>   the wide range of implementations suited to different purposes.
> * polymorphism lets you do general adaptors, like Edison's SizedSeq
>   (adding a size) and RevSeq (presenting a reversed view).

I admit, that supplying further modules for SizedSeq and RevSeq would 
involve some code duplication. (If several implementations of sequences 
are used simultaneously qualification is required.)

But maybe you could elaborate the advantages of a class that you suggest 
in more detail. For generic algorithms with sequences, I would suspect 
smaller classes, e.g. like Monoid, to be more appropriate.



where can I download the actual code of edison?

More information about the Libraries mailing list