in reply to Re: Timing of Array-Size Determination Methods
in thread Timing of Array-Size Determination Methods
Because "scalar" is unary operatorSo no it's not a function call at all, even if looks like one. (Just like split.)
Certainly looks like $#arr + 1 loses that argument as well. Not that it mattered in the first place..$ perl -MO=Terse -e'scalar @_' LISTOP (0x8133508) leave [1] OP (0x8133370) enter COP (0x8133400) nextstate UNOP (0x81333c0) scalar UNOP (0x8133630) rv2av [1] SVOP (0x8133540) gv GV (0x8124334) *_ -e syntax OK $ perl -MO=Terse -e'$#_+1' LISTOP (0x8133440) leave [1] OP (0x8128040) enter COP (0x8133400) nextstate BINOP (0x8133508) add [2] UNOP (0x81333c0) av2arylen UNOP (0x8133630) rv2av [1] SVOP (0x8133540) gv GV (0x8124334) *_ SVOP (0x8133370) const IV (0x8132bdc) 1 -e syntax OK
Makeshifts last the longest.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re^2: Timing of Array-Size Determination Methods (scalar() != function)
by Juerd (Abbot) on Jun 03, 2003 at 05:32 UTC | |
by Aristotle (Chancellor) on Jun 03, 2003 at 11:11 UTC |