Thomas Wouters wrote:
> The only meaning is by accident of position. For most programs, the very 
> same thing goes for the rest of the arguments: 'mv foo bar' assigns a 
> different meaning to 'foo' than it does to 'bar'. Notice how sys.argv 
> matches what the user typed, including sys.argv[0].

But most users don't think of the 'mv' in 'mv foo bar'
as being an argument in any normal sense of the word.
It's the thing the arguments are passed *to*, not an
argument itself.

Also, most programs aren't interested in argv[0] at
all, and those that are treat it in a very different
way from the rest of argv.

I still think that argv[0] is in the "too clever by
half" category. It has a kind of theoretical elegance
from a certain point of view, but no practical
benefit that I can see.

-- 
Greg Ewing, Computer Science Dept, +--------------------------------------+
University of Canterbury,          | Carpe post meridiem!                 |
Christchurch, New Zealand          | (I'm not a morning person.)          |
[EMAIL PROTECTED]          +--------------------------------------+
_______________________________________________
Python-3000 mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe: 
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com

Reply via email to