module Hamster

def iterate(item, &block)

Other tags:
    Api: - public

Other tags:
    Yieldreturn: - The next value

Other tags:
    Yieldparam: The - previous value

Parameters:
  • item (Object) -- Starting value
def iterate(item, &block)
  Stream.new { Sequence.new(item, iterate(yield(item), &block)) }
end