in reply to Re^2: Overriding several methods using 'local'
in thread Overriding several methods using 'local'
This is where inheritance is quite useful.
package My::AnyPackage; use base 'AnyPackage'; sub can_read { 1 };
Now, whenever you would do my $obj = AnyPackage->new( ... );, instead you now do my $obj = My::AnyPackage->new( ... );. And it will "Just Work".
|
|---|