Author: Mark Young <marky1...@gmail.com>
Branch: py3.3
Changeset: r82206:00c150ed026d
Date: 2016-02-13 00:20 -0500
http://bitbucket.org/pypy/pypy/changeset/00c150ed026d/

Log:    Fix translation.

diff --git a/pypy/interpreter/mixedmodule.py b/pypy/interpreter/mixedmodule.py
--- a/pypy/interpreter/mixedmodule.py
+++ b/pypy/interpreter/mixedmodule.py
@@ -66,11 +66,9 @@
         # overwrite the value of a key already in w_initialdict. (So as to 
avoid
         # overriding the builtin value with a user-provided value)
         if not self.space.is_none(self.w_initialdict):
-            new_items = self.w_dict.iteritems()
-            while True:
-                w_key, w_value = new_items.next_item()
-                if w_key is None:
-                    break
+            w_items = 
self.space.iteriterable(self.space.call_method(self.w_dict,'items'))
+            for w_item in w_items:
+                w_key, w_value = self.space.fixedview(w_item, 
expected_length=2)
                 if not 
self.space.is_true(self.space.contains(self.w_initialdict, w_key)):
                     self.space.setitem(self.w_initialdict, w_key, w_value)
         else:
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to