diff options
author | Philip Jenvey <pjenvey@underboss.org> | 2015-12-21 23:16:37 -0800 |
---|---|---|
committer | Philip Jenvey <pjenvey@underboss.org> | 2015-12-21 23:16:37 -0800 |
commit | 563ee2cadf38eab9b94e2c15339c72e2a4f59968 (patch) | |
tree | 9e9a8346b90ced987f08e787c2165747c0596b74 /lib-python/2.7/lib2to3 | |
parent | Upgrade 2.7 stdlib to 2.7.10 (diff) | |
download | pypy-563ee2cadf38eab9b94e2c15339c72e2a4f59968.tar.gz pypy-563ee2cadf38eab9b94e2c15339c72e2a4f59968.tar.bz2 pypy-563ee2cadf38eab9b94e2c15339c72e2a4f59968.zip |
update the 2.7 stdlib to 2.7.11
Diffstat (limited to 'lib-python/2.7/lib2to3')
-rw-r--r-- | lib-python/2.7/lib2to3/fixes/fix_metaclass.py | 2 | ||||
-rw-r--r-- | lib-python/2.7/lib2to3/fixes/fix_types.py | 2 | ||||
-rw-r--r-- | lib-python/2.7/lib2to3/refactor.py | 2 | ||||
-rw-r--r-- | lib-python/2.7/lib2to3/tests/test_fixers.py | 4 |
4 files changed, 7 insertions, 3 deletions
diff --git a/lib-python/2.7/lib2to3/fixes/fix_metaclass.py b/lib-python/2.7/lib2to3/fixes/fix_metaclass.py index 4f5593c5fe..8399a13004 100644 --- a/lib-python/2.7/lib2to3/fixes/fix_metaclass.py +++ b/lib-python/2.7/lib2to3/fixes/fix_metaclass.py @@ -114,7 +114,7 @@ def find_metas(cls_node): left_node = expr_node.children[0] if isinstance(left_node, Leaf) and \ left_node.value == u'__metaclass__': - # We found a assignment to __metaclass__. + # We found an assignment to __metaclass__. fixup_simple_stmt(node, i, simple_node) remove_trailing_newline(simple_node) yield (node, i, simple_node) diff --git a/lib-python/2.7/lib2to3/fixes/fix_types.py b/lib-python/2.7/lib2to3/fixes/fix_types.py index fc9d495927..baaeabd972 100644 --- a/lib-python/2.7/lib2to3/fixes/fix_types.py +++ b/lib-python/2.7/lib2to3/fixes/fix_types.py @@ -42,7 +42,7 @@ _TYPE_MAPPING = { 'NotImplementedType' : 'type(NotImplemented)', 'SliceType' : 'slice', 'StringType': 'bytes', # XXX ? - 'StringTypes' : 'str', # XXX ? + 'StringTypes' : '(str,)', # XXX ? 'TupleType': 'tuple', 'TypeType' : 'type', 'UnicodeType': 'str', diff --git a/lib-python/2.7/lib2to3/refactor.py b/lib-python/2.7/lib2to3/refactor.py index a4c168df9e..bd238978b4 100644 --- a/lib-python/2.7/lib2to3/refactor.py +++ b/lib-python/2.7/lib2to3/refactor.py @@ -255,7 +255,7 @@ class RefactoringTool(object): fixer = fix_class(self.options, self.fixer_log) if fixer.explicit and self.explicit is not True and \ fix_mod_path not in self.explicit: - self.log_message("Skipping implicit fixer: %s", fix_name) + self.log_message("Skipping optional fixer: %s", fix_name) continue self.log_debug("Adding transformation: %s", fix_name) diff --git a/lib-python/2.7/lib2to3/tests/test_fixers.py b/lib-python/2.7/lib2to3/tests/test_fixers.py index 7db9af217b..6fa603fd39 100644 --- a/lib-python/2.7/lib2to3/tests/test_fixers.py +++ b/lib-python/2.7/lib2to3/tests/test_fixers.py @@ -3263,6 +3263,10 @@ class Test_types(FixerTestCase): a = """type(None)""" self.check(b, a) + b = "types.StringTypes" + a = "(str,)" + self.check(b, a) + class Test_idioms(FixerTestCase): fixer = "idioms" |