Trying using 'base' to inherit methods from another module and avoid automatically importing methods.
No one said B::moo was a method. For example, B::moo could be Encode::encode
{ package Child; use Base qw( ); use Encode qw( encode ); our @ISA = 'Base'; sub another_method { ... my $x = encode('UTF-16le', $y); ... } } { package Base; sub encode { ... } sub some_method { ... my $c = $self->encode($p); # Can call Encode::encode($self,$p)! ... } } Child->new()->some_method();
In reply to Re^2: Need help with clashing method names
by ikegami
in thread Need help with clashing method names
by dk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |