I would like to build a class that includes a method to move data from one 
arbitrary functor to another, a natural transformation.   The structures might 
be more than just functors, but I can start with that.  I ran into some 
practical issues with resolving the type variables for my multiparameter type 
class, which I can resolve with functional dependencies.   I can also not 
isolate the natural transformation from my overall operation, muddling it with 
the element transformation.  I was wondering if anyone had any words of advice, 
example  or warning about this kind of function or method in general?

Class (Functor f, Functor g) => Foo f g a where
  foo :: f a -> g a
  bar :: (a->b) -> g a -> g b

Thanks,

Gordon J. Uszkay, McMaster University
[email protected]



_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to