diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 1997-11-23 07:32:24 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1997-11-23 07:32:24 +0000 |
commit | 977336f534851e24a2161d3011e030ea4043a2ae (patch) | |
tree | 07beb54d20d60e02081f980535a2c7bb65bc07b0 /pod | |
parent | 0da4822f11e97ce202166899552c06d720eb835a (diff) | |
download | perl-977336f534851e24a2161d3011e030ea4043a2ae.tar.gz |
Add to docs about the BEGIN { shift } feature. Make the change
yet simpler using CvUNIQUE(compcv) instead of subline (Chip's idea).
p4raw-id: //depot/win32/perl@284
Diffstat (limited to 'pod')
-rw-r--r-- | pod/perlfunc.pod | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod index aa1e82eac8..887f827381 100644 --- a/pod/perlfunc.pod +++ b/pod/perlfunc.pod @@ -2856,10 +2856,12 @@ argument. Shifts the first value of the array off and returns it, shortening the array by 1 and moving everything down. If there are no elements in the array, returns the undefined value. If ARRAY is omitted, shifts the -@ARGV array in the main program, and the @_ array in subroutines. -(This is determined lexically.) See also unshift(), push(), and pop(). -Shift() and unshift() do the same thing to the left end of an array -that pop() and push() do to the right end. +@_ array within the lexical scope of subroutines and formats, and the +@ARGV array at file scopes or within the lexical scopes established by +the C<eval ''>, C<BEGIN {}>, C<END {}>, and C<INIT {}> constructs. +See also unshift(), push(), and pop(). Shift() and unshift() do the +same thing to the left end of an array that pop() and push() do to the +right end. =item shmctl ID,CMD,ARG |