2013-10-08 | Paul Boddie | file changeset files shortlog | Supported relative imports in report output; made get_module_name a common function. | syspython-as-target |
paul@665 | 1 | #!/usr/bin/env python |
paul@665 | 2 | |
paul@665 | 3 | class C: |
paul@665 | 4 | def f(self): |
paul@665 | 5 | return 1 |
paul@665 | 6 | |
paul@665 | 7 | def g(self): |
paul@665 | 8 | return 2 |
paul@665 | 9 | |
paul@665 | 10 | def f(self): # is f#2 |
paul@665 | 11 | return 3 |
paul@665 | 12 | |
paul@665 | 13 | g = f # g = f#2 |
paul@665 | 14 | |
paul@665 | 15 | def f(self): # is f#3 |
paul@665 | 16 | return 5 |
paul@665 | 17 | |
paul@665 | 18 | c = C() |
paul@665 | 19 | result1_3 = c.f() |
paul@665 | 20 | result2_3 = c.g() |
paul@665 | 21 | |
paul@665 | 22 | # vim: tabstop=4 expandtab shiftwidth=4 |