diff options
author | Florian Ragwitz <rafl@debian.org> | 2009-04-08 03:37:43 +0200 |
---|---|---|
committer | Florian Ragwitz <rafl@debian.org> | 2009-04-08 03:37:43 +0200 |
commit | 082b74eb74586857de13c8c1c1d19f6f3a2da06e (patch) | |
tree | 8f8bdb6543704ea70c238373c5a7701021f8ca42 /lib/NEXT.pm | |
parent | 9fd5bac037f142635de54421551d6c2d35ca66ed (diff) | |
download | perl-082b74eb74586857de13c8c1c1d19f6f3a2da06e.tar.gz |
Upgrade to NEXT-0.62.
Diffstat (limited to 'lib/NEXT.pm')
-rw-r--r-- | lib/NEXT.pm | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/lib/NEXT.pm b/lib/NEXT.pm index dc3127763b..053ee1097d 100644 --- a/lib/NEXT.pm +++ b/lib/NEXT.pm @@ -1,5 +1,5 @@ package NEXT; -$VERSION = '0.61'; +$VERSION = '0.62'; use Carp; use strict; use overload (); @@ -61,11 +61,19 @@ sub NEXT::ELSEWHERE::buildAUTOLOAD last if shift @forebears eq $caller_class } no strict 'refs'; - @{$NEXT::NEXT{$key,$wanted_method}} = - map { *{"${_}::$caller_method"}{CODE}||() } @forebears + @{$NEXT::NEXT{$key,$wanted_method}} = + map { + my $stash = \%{"${_}::"}; + ($stash->{$caller_method} && (*{$stash->{$caller_method}}{CODE})) + ? *{$stash->{$caller_method}}{CODE} + : () } @forebears unless $wanted_method eq 'AUTOLOAD'; - @{$NEXT::NEXT{$key,$wanted_method}} = - map { (*{"${_}::AUTOLOAD"}{CODE}) ? "${_}::AUTOLOAD" : ()} @forebears + @{$NEXT::NEXT{$key,$wanted_method}} = + map { + my $stash = \%{"${_}::"}; + ($stash->{AUTOLOAD} && (*{$stash->{AUTOLOAD}}{CODE})) + ? "${_}::AUTOLOAD" + : () } @forebears unless @{$NEXT::NEXT{$key,$wanted_method}||[]}; $NEXT::SEEN->{$key,*{$caller}{CODE}}++; } |