Commit 74aa5c74 authored by Guido van Rossum's avatar Guido van Rossum

Rip out all the u"..." literals and calls to unicode().

parent 3bf5ce40
......@@ -247,11 +247,11 @@ class bdist_wininst (Command):
# Convert cfgdata from unicode to ascii, mbcs encoded
try:
unicode
str
except NameError:
pass
else:
if isinstance(cfgdata, unicode):
if isinstance(cfgdata, str):
cfgdata = cfgdata.encode("mbcs")
# Append the pre-install script
......
......@@ -147,7 +147,7 @@ class build_clib (Command):
raise DistutilsSetupError, \
"each element of 'libraries' must a 2-tuple"
if isinstance(lib[0], basestring) StringType:
if isinstance(lib[0], basestring):
raise DistutilsSetupError, \
"first element of each tuple in 'libraries' " + \
"must be a string (the library name)"
......
......@@ -259,7 +259,7 @@ Your selection [default 1]: ''', end=' ')
if type(value) not in (type([]), type( () )):
value = [value]
for value in value:
value = unicode(value).encode("utf-8")
value = str(value).encode("utf-8")
body.write(sep_boundary)
body.write('\nContent-Disposition: form-data; name="%s"'%key)
body.write("\n\n")
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment