Sha256: 9672c315ae52dbd0edac87b1091e4822ab73ee373caf9a99f0e02cbd051ff8ba

Contents?: true

Size: 1.79 KB

Versions: 12

Compression:

Stored size: 1.79 KB

Contents

o:$YARD::CodeObjects::MethodObject:
@name:each_with_index:@docstringIC:YARD::Docstring"{Iterates the given block for each elements with an index, which
start from 0.  If no block is given, returns an enumerator.
:@objectu:YARD::StubProxy+Enumerable::Enumerator#each_with_index:
@summary0:	@all"�Iterates the given block for each elements with an index, which
start from 0.  If no block is given, returns an enumerator.



@overload with_index
  @yield [(*args), idx]
@overload with_index:@ref_tags[:
@tags[o:YARD::Tags::OverloadTag
;
u;+Enumerable::Enumerator#each_with_index;:with_index;IC;	"
;
u;+Enumerable::Enumerator#each_with_index;0;
"@yield [(*args), idx];[;[o:YARD::Tags::Tag
;
0;0:@types["(*args)"idx:
@text":@tag_name"
yield;0:@parameters[;0:@signature"with_index;"
overloado;
;
u;+Enumerable::Enumerator#each_with_index;;;IC;	"
;
u;+Enumerable::Enumerator#each_with_index;0;
";[;[;0;[;0;"with_index;"
overload:@current_file_has_commentsF:@scope:
instance;[:@docstring_extra0:@files[["enumerator.c0:@namespaceu;Enumerable::Enumerator:
@path"+Enumerable::Enumerator#each_with_index;[:@visibility:public:@source"g/*
 *  call-seq:
 *    e.with_index {|(*args), idx| ... }
 *    e.with_index
 *
 *  Iterates the given block for each elements with an index, which
 *  start from 0.  If no block is given, returns an enumerator.
 *
 */
static VALUE
enumerator_with_index(obj)
    VALUE obj;
{
    struct enumerator *e = enumerator_ptr(obj);
    VALUE memo = 0;
    int argc = 0;
    VALUE *argv = 0;

    RETURN_ENUMERATOR(obj, 0, 0);
    if (e->args) {
    argc = RARRAY_LEN(e->args);
    argv = RARRAY_PTR(e->args);
    }
    return rb_block_call(e->obj, e->meth, argc, argv,
             enumerator_with_index_i, (VALUE)&memo);
}:@source_type:c

Version data entries

12 entries across 12 versions & 2 rubygems

Version Path
pry-doc-0.4.4 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.4.3 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.4.2 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.4.1 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.4.0 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.3.0 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.2.4pre1 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.2.3pre1 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.2.1 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.2.0 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-doc-0.1.5pre1 lib/pry-doc/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat
pry-0.6.9pre1-i386-mingw32 lib/pry/core_docs_18/objects/Enumerable/Enumerator/each_with_index_i.dat