foldable flexible bridges (putting foldable+traversable in prelude) Re: Burning bridges

Manuel M T Chakravarty chak at cse.unsw.edu.au
Tue May 28 03:24:16 CEST 2013


As far as beginners and teaching goes, why don't we have two Preludes?

(1) The real (and somewhat scary) Prelude
(2) A stripped down, less flexible, but easier to comprehend Prelude

The DrRacket (ex DrScheme) people have language levels. We could have library levels.

The idea would be that the "SimplePrelude" would only expose a subset of the classes/types/functions of the "real Prelude" and would in many cases only export type instances of the functions in the "real Prelude". For example, map would just be defined for lists in the SimplePrelude, whereas it would be defined for arbitrary functors in the real Prelude.

Manuel


Henning Thielemann <lemming at henning-thielemann.de>:
> On Tue, 21 May 2013, Carter Schonwald wrote:
> 
>> 2) does the change make learning the language more challenging? No. In fact, i've encountered *many* more
>> smart people getting confused as to why the map / fold etc in prelude are all list specific than i've seen
>> people struggle with type classes.
> 
> The Haskell beginners I know, even have problems with 'map' and even more 'fold' being higher order functions.




More information about the Libraries mailing list