in reply to Failing inheritance or what can make a Child disinherited ?
It doesn't give the same error as$ perl -we'sub foo; my $obj = bless {}, "main"; $obj->foo()' Undefined subroutine &main::foo called at -e line 1.
because the method is located; it's just not defined.$ perl -we'my $obj = bless {}, "main"; $obj->foo()' Can't locate object method "foo" via package "main" at -e line 1.
|
|---|