diff options
author | Father Chrysostomos <sprout@cpan.org> | 2013-09-01 14:47:38 -0700 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2013-09-01 14:47:38 -0700 |
commit | 3df5c4b513c5e5c2f25d831f556f2a1c5693ce98 (patch) | |
tree | df8369277985791b3c6d12df55c52c32bcb95b1d /t/mro/basic.t | |
parent | cbf45e8454c586302a9f324433b3155521872636 (diff) | |
download | perl-3df5c4b513c5e5c2f25d831f556f2a1c5693ce98.tar.gz |
Teach mro code about null array elements
This is part of ticket #119433.
Commit ce0d49f changed AVs to use NULL for nonexistent elements. The
mro lookup code was not accounting for that, causing Class::Contract’s
tests to crash (and perhaps other modules, too).
Diffstat (limited to 't/mro/basic.t')
-rw-r--r-- | t/mro/basic.t | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/t/mro/basic.t b/t/mro/basic.t index 65090732f7..5625b5190e 100644 --- a/t/mro/basic.t +++ b/t/mro/basic.t @@ -8,7 +8,7 @@ BEGIN { @INC = '../lib'; require q(./test.pl); } -plan(tests => 60); +plan(tests => 61); require mro; @@ -389,3 +389,9 @@ undef $x; # should use the new DESTROY is $destroy_output, "new", 'Changes to UNIVERSAL::DESTROY invalidate DESTROY caches'; undef *UNIVERSAL::DESTROY; + +{ + no warnings 'uninitialized'; + $#_119433::ISA++; + pass "no crash when ISA contains nonexistent elements"; +} |