Functor => Pointed => Applicative => Monad

wren ng thornton wren at
Sun Dec 5 04:11:33 CET 2010

On 12/4/10 12:31 PM, Malcolm Wallace wrote:
> On 4 Dec 2010, at 06:25, wren ng thornton wrote:
>> Well the paradigmatic (programming) examples of functors are all
>> container-like structures: sets, multisets, lists, trees,...
> Really? Just as monads are not (only) containers, I think it is a
> mistake to think of functors as (only) containers too.

I never said they were only containers, I said that the paradigmatic 
ones for programming (i.e., the first examples cited) tend to be. 
Parsers, continuations, and the like tend to come afterwards--- once 
people have already become familiar with the basic idea of functors. I 
think one of the telling things about containers (as a subclass of 
functors) is that, while most of them form co/monads, we tend to think 
about them more primarily as functors, i.e. as things with stuff inside 
that we can change homogeneously. Whereas parsers and the like are more 
often thought of first as applicative/monadic structures and the 
functorality just comes along for the ride.

Live well,

More information about the Libraries mailing list