Welcome to the Monastery | |
PerlMonks |
Re: Number of times I've used goto in Perlby HugoNo1 (Novice) |
on Sep 26, 2018 at 11:07 UTC ( [id://1223045]=note: print w/replies, xml ) | Need Help?? |
Surprisingly nobody has commented on this nice use of the goto Function
Which has the nice effect: it exits the current subroutine (losing any changes set by local) and immediately calls in its place the named subroutine using the current value of @_ .
That way the Parameters won't be copied again when you go from oldFunctionName() to newFunctionName()
I also found this often in Modules as:
In Section
Past Polls
|
|