appEval :: forall a (b :: TYPE rep).
(a -> b) -> Eval a -> b
appEval f (Eval (IO m)) =
case runRW# m of
(# _, a #) -> f a
Ignoring levity polymorphism, this could be implemented
appEval f m = runEval (f <$> m)
Moreover,
But what makes this interesting, I think, is its relationship with >>=
: aside from arity wibbles,
This strikes me as a really pleasant property.