2009-11-24 | Paul Boddie | raw annotate files changeset graph | Introduced proper object visit tracking when collecting attributes. Fixed deletion flags testing where augmented assignment employs AssName nodes. Fixed loop assignment so that outer loop variables are not considered constant. Exposed the importer via a convenience variable in the test program. |
1 #!/usr/bin/env python 2 3 class C: 4 def f(self): # unused 5 return 1 6 7 class D: 8 def f(self): 9 return 2 10 11 def g(self): 12 return 3 13 14 class E: 15 def f(self): # unused 16 return 4 17 18 def h(self): # unused 19 return 5 20 21 def test_one(obj): 22 # obj: D (f, g) 23 obj.f() # C, D, E (f) 24 return obj.g() # D (f, g) 25 26 c = C() 27 d = D() 28 e = E() 29 result1_3 = test_one(d) 30 31 # vim: tabstop=4 expandtab shiftwidth=4