[Haskell-cafe] lecture notes for Finally Tagless - benefit of explicit fix combinator

Günther Schmidt gue.schmidt at web.de
Sat Jun 19 09:01:09 EDT 2010


Hi all,

I'm working my way through the lecture notes to the "Finally Tagless" 
course, available from:
	
	http://okmij.org/ftp/tagless-final/course/index.html

As usual at every round of doing so, I think it's my 4th, I discover 
something new, something that hadn't occurred to me previously.

This time it's a comment in the code of SerializeExt.hs

-- * Tie up the knot
fromTree = S.fix fromTreeExt		-- One does use fix in real programs

-- Now we can see the real benefit of using fix in real programs.
-- The fixpoint combinator is NOT a mere curiosity

about the fix-point combinator.

I don't think I can deduce what he meant by that from the context alone, 
could somebody please enlighten me? I'm refering to the benefit of using 
the fix-point combinator in this particular scenario.


Günther



More information about the Haskell-Cafe mailing list