use Params::Validate;
sub foo { my ($self, $object_or_class) = validate_pos( @_, 1, # or strictly, { isa => __PACKAGE__, type => +OBJECT }, { can => \ @methods } ); .... }
In reply to Re: Class capabilities
by diotalevi
in thread Class capabilities
by Ovid
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |