At 09:13 +0300 1998/11/16, S.D.Mechveliani wrote:
>> In the Prelude
>> ~~~~~~~~~~~~~~~
>>
>> class Functor f where
>> fmap :: (a -> b) -> f a -> f b
>
>
>What about renaming it, say, to Mappable f ?
>
>It looks like the word `functor' is taken from the very category
>theory and restricted in the recent Haskell to the subcategories of
>Set.
To begin with, one should not confuse the "category" Haskell provides with
the category of Sets. Then, I do not think that Haskell aims at providing
all possible categories: It is simply named functor because that is the
mathematical inspiration.
So, within those interpretations, it is a functor, but not a description of
all functors, or even a functor in the strict mathematical sense.
Then this name is acceptable to me, because that is the state of the art of
programming.
But if you have a better way to implement more general categories in
Haskell, then I think that one might need changing the name as you propose.
Hans Aberg
* Email: Hans Aberg <mailto:[EMAIL PROTECTED]>
* Home Page: <http://www.matematik.su.se/~haberg/>
* AMS member listing: <http://www.ams.org/cml/>