diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 1999-12-01 19:09:31 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1999-12-01 19:09:31 +0000 |
commit | f784dfa3907dda58a76b5d8c67d99274984dc87a (patch) | |
tree | c396eb52eade217633c030017e4dfa21b50b516e /pod | |
parent | cc3604b14c0748189384ba69182e0ae2c73a4d88 (diff) | |
download | perl-f784dfa3907dda58a76b5d8c67d99274984dc87a.tar.gz |
more accurate require() pseudocode (from James P. Williams
<James.P.Williams@USAHQ.UnitedSpaceAlliance.com>)
p4raw-id: //depot/perl@4610
Diffstat (limited to 'pod')
-rw-r--r-- | pod/perlfunc.pod | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod index 16da798a02..fa67babc57 100644 --- a/pod/perlfunc.pod +++ b/pod/perlfunc.pod @@ -3424,15 +3424,16 @@ subroutine: foreach $prefix (@INC) { $realfilename = "$prefix/$filename"; if (-f $realfilename) { + $INC{$filename} = $realfilename; $result = do $realfilename; last ITER; } } die "Can't find $filename in \@INC"; } + delete $INC{$filename} if $@ || !$result; die $@ if $@; die "$filename did not return true value" unless $result; - $INC{$filename} = $realfilename; return $result; } |