Subject: | Can't call method "isa" without a package or object reference at C:\Test-Class-0.09\blib\lib/Test/Class.pm line 253 |
Devel::Symdump->rnew->packages;
will return as one of the values 0 (also known as main::0),
and 0->isa(0) will trigger an error,
so to fix it change line 252 from
grep { defined $_ && $_->isa( $class ) } Devel::Symdump->rnew->packages;
to
grep { $_ && $_->isa( $class ) } Devel::Symdump->rnew->packages;
as the values will always be defined.
You could also test for "main::$_"->isa($class) and avoid the truth test
altogether, but that feels like cheating :)