On 15/09/2008, at 21:16, Simon Peyton-Jones wrote:
| > What would we like to write? Perhaps something like
| >
| > "myrule" forall (type t :: *->*) (f :: a->a) x.
| > from (tmap f (to x :: t a)) = map f (from (to x :: t a))
|
| Regardless of the syntax, I suspect x will have to be given a t
| > What would we like to write? Perhaps something like
| >
| > "myrule" forall (type t :: *->*) (f :: a->a) x.
| > from (tmap f (to x :: t a)) = map f (from (to x :: t a))
|
| Regardless of the syntax, I suspect x will have to be given a type as
| well here, as in (x :: a)?
No, that's easily
On 15/09/2008, at 20:05, Simon Peyton-Jones wrote:
What would we like to write? Perhaps something like
"myrule" forall (type t :: *->*) (f :: a->a) x.
from (tmap f (to x :: t a)) = map f (from (to x :: t a))
Regardless of the syntax, I suspect x will have to be given a type as
well her
[Widening to cvs-ghc; read Roman's message below first.]
Roman
How annoying. You're right, it's impossible, because the 't' isn't mentioned in
the type of 'f', or 'x'.
What would we like to write? Perhaps something like
"myrule" forall (type t :: *->*) (f :: a->a) x.
from (tmap f (to x :