I mean why would I want to push a subroutine to an array?
To create a list of actions to take once the program has finished being configured. These actions can be executed as followed:
$_->() for @actions;
In reply to Re: Getopt::Long. forms => sub { push( @actions, \&dump_forms ); },
by ikegami
in thread Getopt::Long. forms => sub { push( @actions, \&dump_forms ); },
by gctaylor1
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |