Method: Dir#tell

Defined in:
dir.c

#posInteger #tellInteger

Returns the current position in dir. See also Dir#seek.

d = Dir.new("testdir")
d.tell   #=> 0
d.read   #=> "."
d.tell   #=> 12

Overloads:

[View source]

850
851
852
853
854
855
856
857
858
859
# File 'dir.c', line 850

static VALUE
dir_tell(VALUE dir)
{
    struct dir_data *dirp;
    long pos;

    GetDIR(dir, dirp);
    pos = telldir(dirp->dir);
    return rb_int2inum(pos);
}