[Python-checkins] python/dist/src/Lib/distutils fancy_getopt.py,
1.28, 1.29
fdrake at users.sourceforge.net
fdrake at users.sourceforge.net
Mon Aug 2 19:58:53 CEST 2004
Update of /cvsroot/python/python/dist/src/Lib/distutils
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24629
Modified Files:
fancy_getopt.py
Log Message:
- fix description of option table entries
- fix broken assert statement; should just raise
Index: fancy_getopt.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/distutils/fancy_getopt.py,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -d -r1.28 -r1.29
*** fancy_getopt.py 12 Feb 2004 17:35:08 -0000 1.28
--- fancy_getopt.py 2 Aug 2004 17:58:51 -0000 1.29
***************
*** 46,51 ****
def __init__ (self, option_table=None):
! # The option table is (currently) a list of 3-tuples:
! # (long_option, short_option, help_string)
# if an option takes an argument, its long_option should have '='
# appended; short_option should just be a single character, no ':'
--- 46,52 ----
def __init__ (self, option_table=None):
! # The option table is (currently) a list of tuples. The
! # tuples may have 3 or four values:
! # (long_option, short_option, help_string [, repeatable])
# if an option takes an argument, its long_option should have '='
# appended; short_option should just be a single character, no ':'
***************
*** 163,167 ****
# the option table is part of the code, so simply
# assert that it is correct
! assert "invalid option tuple: %r" % (option,)
# Type- and value-check the option names
--- 164,168 ----
# the option table is part of the code, so simply
# assert that it is correct
! raise ValueError, "invalid option tuple: %r" % (option,)
# Type- and value-check the option names
More information about the Python-checkins
mailing list