Author: Manuel Jacob <m...@manueljacob.de> Branch: py3.3 Changeset: r82517:34c1abf3cd35 Date: 2016-02-25 17:36 +0100 http://bitbucket.org/pypy/pypy/changeset/34c1abf3cd35/
Log: Intern keyword arguments. diff --git a/pypy/objspace/std/kwargsdict.py b/pypy/objspace/std/kwargsdict.py --- a/pypy/objspace/std/kwargsdict.py +++ b/pypy/objspace/std/kwargsdict.py @@ -11,7 +11,7 @@ def _wrapkey(space, key): - return space.wrap(key.decode('utf-8')) + return space.new_interned_str(key) class EmptyKwargsDictStrategy(EmptyDictStrategy): diff --git a/pypy/objspace/std/test/test_dictmultiobject.py b/pypy/objspace/std/test/test_dictmultiobject.py --- a/pypy/objspace/std/test/test_dictmultiobject.py +++ b/pypy/objspace/std/test/test_dictmultiobject.py @@ -1134,6 +1134,9 @@ def wrapbytes(self, obj): return obj + def new_interned_str(self, s): + return s.decode('utf-8') + def isinstance_w(self, obj, klass): return isinstance(obj, klass) isinstance = isinstance_w _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit