[Haskell-cafe] Type families again

Roman Leshchinskiy rl at cse.unsw.edu.au
Fri Dec 3 00:49:44 CET 2010


On 2 Dec 2010, at 21:29, Andrew Coppin <andrewcoppin at btinternet.com> wrote:

> Does anybody have any suggestions?

class Mappable t a b where
 type Rebind t a b
 map :: (a -> b) -> t -> Rebind a b

This is based on an old C++ trick.

Roman

> 





More information about the Haskell-Cafe mailing list