cleanup GetAttrGetItemRedirect test.
authorRobert Bradshaw <robertwb@math.washington.edu>
Wed, 15 Sep 2010 04:44:29 +0000 (21:44 -0700)
committerRobert Bradshaw <robertwb@math.washington.edu>
Wed, 15 Sep 2010 04:44:29 +0000 (21:44 -0700)
tests/run/special_methods_T561.pyx

index 27cce9cfecca2fb789336bae594045868ba4266d..1d37d20833ca266dee0f2b46a01b39de7d1b8314 100644 (file)
@@ -544,10 +544,10 @@ cdef class GetAttrGetItemRedirect:
 
     def __getattr__(self, name):
         if name == 'item':
-            return self.__getitem__(name)
+            return self[name]
         return ('attr', self.obj)
 
     def __getitem__(self, key):
         if key == 'attr':
-            return self.__getattr__(key)
+            return getattr(self, key)
         return ('item', self.obj)