Author: Carl Friedrich Bolz <[email protected]>
Branch: 
Changeset: r48728:c15bbb59c756
Date: 2011-11-03 20:11 +0100
http://bitbucket.org/pypy/pypy/changeset/c15bbb59c756/

Log:    similarly, no need to call length here

diff --git a/pypy/objspace/std/smalltupleobject.py 
b/pypy/objspace/std/smalltupleobject.py
--- a/pypy/objspace/std/smalltupleobject.py
+++ b/pypy/objspace/std/smalltupleobject.py
@@ -68,7 +68,7 @@
             raise IndexError
 
         def eq(self, space, w_other):
-            if self.length() != w_other.length():
+            if n != w_other.length():
                 return space.w_False
             for i in iter_n:
                 item1 = getattr(self,'w_value%s' % i)
@@ -80,7 +80,7 @@
         def hash(self, space):
             mult = 1000003
             x = 0x345678
-            z = self.length()
+            z = n
             for i in iter_n:
                 w_item = getattr(self, 'w_value%s' % i)
                 y = space.int_w(space.hash(w_item))
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to