Class: Enumerator::Yielder
Instance Method Summary collapse
-
#<<(args) ⇒ Object
:nodoc:.
-
#initialize ⇒ Object
constructor
:nodoc:.
-
#yield(args) ⇒ Object
:nodoc:.
Constructor Details
#initialize ⇒ Object
:nodoc:
1125 1126 1127 1128 1129 1130 1131 |
# File 'enumerator.c', line 1125
static VALUE
yielder_initialize(VALUE obj)
{
rb_need_block();
return yielder_init(obj, rb_block_proc());
}
|
Instance Method Details
#<<(args) ⇒ Object
:nodoc:
1143 1144 1145 1146 1147 1148 |
# File 'enumerator.c', line 1143
static VALUE
yielder_yield_push(VALUE obj, VALUE args)
{
yielder_yield(obj, args);
return obj;
}
|
#yield(args) ⇒ Object
:nodoc:
1134 1135 1136 1137 1138 1139 1140 |
# File 'enumerator.c', line 1134
static VALUE
yielder_yield(VALUE obj, VALUE args)
{
struct yielder *ptr = yielder_ptr(obj);
return rb_proc_call(ptr->proc, args);
}
|