Hi all,
I'm trying to figure out how to express the Y-Combitor in this Finally Tagless EDSL:
class Symantics exp where
lam :: (exp a -> exp b) -> exp (exp a -> exp b)
app :: exp (exp a -> exp b) -> exp a -> exp b
fix :: ...
fix f = .....
I'm not certain but I think a default implementation of the Y-Combinator should be possible using "lam" and "app".
Anybody know how? My first attempts fail because of the "cannot construct the infinite type" thingy.
Cheers, Günther