Max Bolingbroke <[email protected]> writes: > I would suppose that there is some trivial way to run > sufficiently-polymorphic modally-typed stuff as simple Haskell by > taking g = (->), which would be good to show. (Speaking of which, > wouldn't it make sense to have that GArrow instance in > GHC.HetMet.GArrow?)
Okay, done: http://git.megacz.com/?p=ghc-base.git;a=commitdiff;h=da198a317e7da7e Every Control.Arrow is a GArrow, and I've added the instance for it. So now you can use the instance "Arrow (->)" as a GArrow: http://www.haskell.org/ghc/docs/latest/html/libraries/base/src/Control-Arrow.html#line-115 ... but, of course, this can only be used to interpret fully-polymorphic GArrow terms (i.e., type "(GArrow g)=>g a b" for potentially-instantiated "a" and "b"). To clarify my earlier comment, there is no "general-purpose run" for GArrows in the sense that there is no term of the following type that "does what you think it should": forall g a b. (GArrow g) => (g a b) -> (a -> b) - a _______________________________________________ Cvs-ghc mailing list [email protected] http://www.haskell.org/mailman/listinfo/cvs-ghc
