See Original text in context
sub RUN-MAIN(, , :)
This routine allows complete control over the handling of MAIN
. It gets a Callable
that is the MAIN
that should be executed, the return value of the mainline execution and additional named variables: :in-as-argsfiles
which will be True
if STDIN should be treated as $*ARGFILES
.
If RUN-MAIN
is not provided, a default one will be run that looks for subroutines of the old interface, such as MAIN_HELPER
and USAGE
. If found, it will execute following the "old" semantics.
sub new-main(, * )RUN-MAIN( , Nil );
This will print the name (first argument) of the generated object.