Personal tools

Talk:Enumerator and iteratee

From HaskellWiki

(Difference between revisions)
Jump to: navigation, search
m
 
Line 1: Line 1:
 
* introduces analogy and then says not to hold to the analogy too closely.. is this analogy that useful? perhaps it should be discarded.
 
* introduces analogy and then says not to hold to the analogy too closely.. is this analogy that useful? perhaps it should be discarded.
  +
:: I am the author of a big part of text and code. That analogy is not mine. Because somebody found it helping, I was reluctant to delete it. Delete that analogy (I agree) or link it somehow to remaining text. --[[User:Beroal|beroal]] 20:33, 26 August 2011 (UTC)
 
* makes use of fix to write recursive functions easily, but that might be a stumbling block for less experienced programmers
 
* makes use of fix to write recursive functions easily, but that might be a stumbling block for less experienced programmers
  +
:: It depends on background (a textbook). Introducing recursion with the fixed point combinator IMHO is more elementary than with recursive @let@. --[[User:Beroal|beroal]] 20:33, 26 August 2011 (UTC)
 
* monad,functor,category discussion is very terse..
 
* monad,functor,category discussion is very terse..
  +
:: "it works exactly like a monadic parser". I supposed that [[monadic parser]] would be written shortly after that, but that did not happen. :) (Or is there a suitable article, but with another name?) In short: @fmap f@ passes an output message via @f@ (@Next g -> Next (rc . g)@ just wraps the automaton given as argument); @return x@ is an automaton that finishes immediately and yields @x@; @it0 >>= it1@ runs @it0@ until it finishes yielding @x@, then runs @it1 x@. --[[User:Beroal|beroal]] 20:33, 26 August 2011 (UTC)

Latest revision as of 20:33, 26 August 2011

  • introduces analogy and then says not to hold to the analogy too closely.. is this analogy that useful? perhaps it should be discarded.
I am the author of a big part of text and code. That analogy is not mine. Because somebody found it helping, I was reluctant to delete it. Delete that analogy (I agree) or link it somehow to remaining text. --beroal 20:33, 26 August 2011 (UTC)
  • makes use of fix to write recursive functions easily, but that might be a stumbling block for less experienced programmers
It depends on background (a textbook). Introducing recursion with the fixed point combinator IMHO is more elementary than with recursive @let@. --beroal 20:33, 26 August 2011 (UTC)
  • monad,functor,category discussion is very terse..
"it works exactly like a monadic parser". I supposed that monadic parser would be written shortly after that, but that did not happen. :) (Or is there a suitable article, but with another name?) In short: @fmap f@ passes an output message via @f@ (@Next g -> Next (rc . g)@ just wraps the automaton given as argument); @return x@ is an automaton that finishes immediately and yields @x@; @it0 >>= it1@ runs @it0@ until it finishes yielding @x@, then runs @it1 x@. --beroal 20:33, 26 August 2011 (UTC)