summaryrefslogtreecommitdiff
path: root/fancy_getopt.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2007-10-16 18:12:55 +0000
committerGuido van Rossum <guido@python.org>2007-10-16 18:12:55 +0000
commitd593487053de01cd756914a5cb5cc6b058c99c03 (patch)
tree49199b1cdcd30b83e2250b9696ba9342a004a261 /fancy_getopt.py
parent27cd6610b468d4cc03dea2c22d74aa3c281d3a66 (diff)
downloadpython-setuptools-git-d593487053de01cd756914a5cb5cc6b058c99c03.tar.gz
Patch# 1258 by Christian Heimes: kill basestring.
I like this because it makes the code shorter! :-)
Diffstat (limited to 'fancy_getopt.py')
-rw-r--r--fancy_getopt.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/fancy_getopt.py b/fancy_getopt.py
index b3231c3d..72441fb4 100644
--- a/fancy_getopt.py
+++ b/fancy_getopt.py
@@ -154,12 +154,12 @@ class FancyGetopt:
raise ValueError("invalid option tuple: %r" % (option,))
# Type- and value-check the option names
- if not isinstance(long, basestring) or len(long) < 2:
+ if not isinstance(long, str) or len(long) < 2:
raise DistutilsGetoptError(("invalid long option '%s': "
"must be a string of length >= 2") % long)
if (not ((short is None) or
- (isinstance(short, basestring) and len(short) == 1))):
+ (isinstance(short, str) and len(short) == 1))):
raise DistutilsGetoptError("invalid short option '%s': "
"must a single character or None" % short)