method
yield
v1_8_7_330 -
Show latest stable
- Class:
Generator
yield(value)public
Yields an element to the generator.
1Note
Block_given?
Kernel#block_given? can be used to check if yield would be able to call a block.
yield(value)Yields an element to the generator.
Kernel#block_given? can be used to check if yield would be able to call a block.