This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
pad.c:pad_findmy_pvn: Skip ‘our’ hack for subs
authorFather Chrysostomos <sprout@cpan.org>
Wed, 27 Aug 2014 06:26:28 +0000 (23:26 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Thu, 28 Aug 2014 20:04:17 +0000 (13:04 -0700)
commitf072719039fbeddb3ffe0c3971cd64af872f5c3d
tree1b3ac197bc922ef5a908415b9a8305076f290d18
parent7f713aaaca2c8ec3ddd03308f09590cc8e915afe
pad.c:pad_findmy_pvn: Skip ‘our’ hack for subs

There is a hack that allows an ‘our’ variable to be found in the pad
in the statement in which it is declared, to avoid a warning (since
the fallback would be to look up the very same variable in the current
package anyway).

Since the warning this hack avoids doesn’t apply to subroutines, we
can just skip it for subroutine lookup.
pad.c