For tied file handle calls, use PUSH* when we know that the stack has space.
[p5sagit/p5-mst-13.2.git] / lib / stat.pl
1 ;# This legacy library is deprecated and will be removed in a future
2 ;# release of perl.
3 ;#
4 ;# Usage:
5 ;#      require 'stat.pl';
6 ;#      @ary = stat(foo);
7 ;#      $st_dev = @ary[$ST_DEV];
8 ;#
9
10 $ST_DEV =       0;
11 $ST_INO =       1;
12 $ST_MODE =      2;
13 $ST_NLINK =     3;
14 $ST_UID =       4;
15 $ST_GID =       5;
16 $ST_RDEV =      6;
17 $ST_SIZE =      7;
18 $ST_ATIME =     8;
19 $ST_MTIME =     9;
20 $ST_CTIME =     10;
21 $ST_BLKSIZE =   11;
22 $ST_BLOCKS =    12;
23
24 ;# Usage:
25 ;#      require 'stat.pl';
26 ;#      do Stat('foo');         # sets st_* as a side effect
27 ;#
28 sub Stat {
29     ($st_dev,$st_ino,$st_mode,$st_nlink,$st_uid,$st_gid,$st_rdev,$st_size,
30         $st_atime,$st_mtime,$st_ctime,$st_blksize,$st_blocks) = stat(shift(@_));
31 }
32
33 1;