Rename 'unicode' to 'str' in its tp_name field. Rename 'str' to 'str8'.

Change all occurrences of unichr to chr.
This commit is contained in:
Guido van Rossum 2007-05-03 17:18:26 +00:00
parent ef87d6ed94
commit 84fc66dd02
17 changed files with 45 additions and 66 deletions

View file

@ -21,7 +21,7 @@ class UnicodeMethodsTest(unittest.TestCase):
def test_method_checksum(self):
h = hashlib.sha1()
for i in range(65536):
char = unichr(i)
char = chr(i)
data = [
# Predicates (single char)
"01"[char.isalnum()],
@ -82,7 +82,7 @@ class UnicodeFunctionsTest(UnicodeDatabaseTest):
h = hashlib.sha1()
for i in range(0x10000):
char = unichr(i)
char = chr(i)
data = [
# Properties
str(self.db.digit(char, -1)),
@ -194,7 +194,7 @@ class UnicodeMiscTest(UnicodeDatabaseTest):
# its numeric value should be the same.
count = 0
for i in xrange(0x10000):
c = unichr(i)
c = chr(i)
dec = self.db.decimal(c, -1)
if dec != -1:
self.assertEqual(dec, self.db.numeric(c))
@ -207,7 +207,7 @@ class UnicodeMiscTest(UnicodeDatabaseTest):
# its numeric value should be the same.
count = 0
for i in xrange(0x10000):
c = unichr(i)
c = chr(i)
dec = self.db.digit(c, -1)
if dec != -1:
self.assertEqual(dec, self.db.numeric(c))