Personally, I'd go with;*{$new_method} = sub { my $self = shift; $self->$main_spelling(@_) }
so that caller() would still work right.*{$new_method} = sub { goto &{$_[0]->can($main_spelling)} }
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
In reply to Re^3: what's a proper way to code method synonyms
by merlyn
in thread what's a proper way to code method synonyms
by leocharre
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |