[Python-ideas] sys.args
Oleg Broytman
phd at phdru.name
Fri Jul 26 16:59:16 CEST 2013
On Fri, Jul 26, 2013 at 05:51:15PM +0300, anatoly techtonik <techtonik at gmail.com> wrote:
> On Fri, Jul 26, 2013 at 5:47 PM, Giampaolo Rodola' <g.rodola at gmail.com> wrote:
> > On Fri, Jul 26, 2013 at 4:39 PM, anatoly techtonik <techtonik at gmail.com> wrote:
> >> sys.argv is an atavism with not intuitive name, how about sys.args for
> >> program arguments only?
> >>
> >> if not sys.args:
> >> print("usage: ...")
> >
> > I'd say the cost in terms of compatibility breakage is way higher than
> > the benefits.
>
> It's not sys.argv replacement, but an alternative that is easy to remember.
There shouldn't be two slightly different but very similar ways to
access command-line arguments. Too much confusion for too little gain.
Oleg.
--
Oleg Broytman http://phdru.name/ phd at phdru.name
Programmers don't die, they just GOSUB without RETURN.
More information about the Python-ideas
mailing list