petdance/scratch — Issue #314: 0-args :main Subs will check passed arguments.
Author: petdance
Created: 2011-11-01 04:25:40+00:00
State: open

After 2.6 we'll enable check arguments of 0-args Subs which can break current :main Sub invocation.

For example
{{{
.sub "foo" :main
say "Hello world"
.end
}}}
will throw an exception if command-line arguments passed.

For updating from current behaviour :main Sub should declare {{{.param pmc args :slurpy}}} to work with any numbers of arguments.

See also #1033 for original "0-args Subs" ticket.

See also http://irclog.perlgeek.de/parrotsketch/2010-07-13#i_2550626 for discussion.