diff options
Diffstat (limited to 'Lib/distutils/cmd.py')
-rw-r--r-- | Lib/distutils/cmd.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/distutils/cmd.py b/Lib/distutils/cmd.py index 66940f7..bd560a6 100644 --- a/Lib/distutils/cmd.py +++ b/Lib/distutils/cmd.py @@ -213,7 +213,7 @@ class Command: if val is None: setattr(self, option, default) return default - elif not isinstance(val, basestring): + elif not isinstance(val, str): raise DistutilsOptionError("'%s' must be a %s (got `%s`)" % (option, what, val)) return val @@ -233,11 +233,11 @@ class Command: val = getattr(self, option) if val is None: return - elif isinstance(val, basestring): + elif isinstance(val, str): setattr(self, option, re.split(r',\s*|\s+', val)) else: if isinstance(val, list): - ok = all(isinstance(v, basestring) for v in val) + ok = all(isinstance(v, str) for v in val) else: ok = False if not ok: @@ -390,7 +390,7 @@ class Command: # Allow 'infiles' to be a single string - if isinstance(infiles, basestring): + if isinstance(infiles, str): infiles = (infiles,) elif not isinstance(infiles, (list, tuple)): raise TypeError( |