in reply to Limit number of Sub routine argument list
Why do you think that you need this feature?
What keeps you from checking the size of @_ in the subroutine?
sub iWantFourArguments { @_==4 or die "Call me with four arguments. Died"; # ... }
Note that prototypes won't help you here, you can bypass them using &subname(...) and they aren't checked at all when subs are invoked as methods.
Alexander
|
|---|