4 ms·
As for "appending infinite lists" I'd like to suggest Control.Monad.Omega: http://hackage.haskell.org/package/control-monad-omega http://hackage.haskell.org/pac
by thesz 15y ago
As for "appending infinite lists" I'd like to suggest Control.Monad.Omega: http://hackage.haskell.org/package/control-monad-omega http://hackage.haskell.org/package/control-monad-omega
"A monad for enumerating sets: like the list monad, but impervious to infinite descent.
A depth-first search of a data structure can fail to give a full traversal if it has an infinitely deep path. Likewise, a breadth-first search of a data structure can fall short if it has an infinitely branching node. Omega addresses this problem by using a "diagonal" traversal that gracefully dissolves such data."