]> granicus.if.org Git - python/commit
Accept a non-list sequence for the long options (request by Jack Jansen).
authorGuido van Rossum <guido@python.org>
Tue, 17 Nov 1998 04:16:37 +0000 (04:16 +0000)
committerGuido van Rossum <guido@python.org>
Tue, 17 Nov 1998 04:16:37 +0000 (04:16 +0000)
commit6d06094c77f08b95f649c7da46a85fffc419f497
treeb95b67796e6ae743ea6fc38da5edaf5dfe0b981d
parente9bc62d993e050fbc0a2b6a5a8b1cee228705196
Accept a non-list sequence for the long options (request by Jack Jansen).

Because it might be a common mistake to pass a single string, this
situation is treated separately.

Since we were making a copy of the longopts list anyway, we now use
the list() function -- this made it necessary to change all uses of
the local variable (and argument) 'list' to something more meaningful,
i.e., 'opts'.

Also added docstrings (copied from the library manual) and removed the
(now redundant) module comments.
Lib/getopt.py