iterateM package:monad-loops

Execute an action forever, feeding the result of each execution as the input to the next.