class Enumerator::Lazy
Public Instance Methods
filter_map {|obj| block } → an_enumerator
click to toggle source
Returns a new lazy Enumerator which
iterates over all non-nil values returned by block
while
obj
iterates over enum
.
# File lib/coroutines.rb, line 51 def filter_map Lazy.new(self) do |yielder, *values| result = yield *values yielder << result if result end end