Hello,
is there a way to defined something as a map to use in tuples? I tried
this:
mapTuple f (a, b) = (f a, f b)
But the type inferred to it is not as generic as I wanted:
mapTuple :: (t -> t1) -> (t, t) -> (t1, t1)
Then I tried a different, but not much, implementation:
mapTuple' f g (a, b) = (f a, g b)
mapTuple f = mapTuple' f f
But the inferred type was the same.
Is there a way to define a function in which I can be able to do
something as this?
mapTuple show ("string", True)
--
malebria
Marco Túlio Gontijo e Silva
Correio (MSN): [EMAIL PROTECTED]
Jabber (GTalk): [EMAIL PROTECTED]
Telefone: 33346720
Celular: 98116720
Endereço:
Rua Paula Cândido, 257/201
Gutierrez 30430-260
Belo Horizonte/MG Brasil
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe