[Haskell-beginners] Abstracting Data.List

Giacomo Tesio giacomo at tesio.it
Fri May 31 11:50:35 CEST 2013


fmap is a much more general concept.. I just want to be able to use map (or
another term, like project) over "enhanced" lists. Such "enhanced" lists
aren't Monads, btw, because I can't write a meaningful return/unit
function: to put the list in context, I always need a context to be
provided.

Giacomo


On Fri, May 31, 2013 at 11:34 AM, Nadir Sampaoli <nadirsampaoli at gmail.com>wrote:

> Hi, I'm very new to Haskell and I don't know about head, take, etc. but I
> think the `Functor` class (and its `fmap` function) provides the
> abstraction for `map` (which, in my understanding, can be considered the
> list-specific `fmap`).
>
>
> 2013/5/31 Giacomo Tesio <giacomo at tesio.it>
>
>> I'm looking for a class abstracting Data.List. I mean something that
>> enable the use of say head, map, take and so on into different kind of
>> types.
>>
>> Is there already something like that?
>>
>>
>> Giacomo
>>
>> _______________________________________________
>> Beginners mailing list
>> Beginners at haskell.org
>> http://www.haskell.org/mailman/listinfo/beginners
>>
>>
>
>
> --
> Nadir
>
> _______________________________________________
> Beginners mailing list
> Beginners at haskell.org
> http://www.haskell.org/mailman/listinfo/beginners
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20130531/3337bf2f/attachment.htm>


More information about the Beginners mailing list