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@404 | 1 | #!/usr/bin/env python |
paul@404 | 2 | |
paul@404 | 3 | class C: |
paul@404 | 4 | clsattr = 123 |
paul@404 | 5 | clsattr2 = 456 |
paul@404 | 6 | |
paul@404 | 7 | def f(cls): |
paul@404 | 8 | cls.clsattr = 789 |
paul@404 | 9 | cls.clsattr2 = 234 |
paul@404 | 10 | |
paul@404 | 11 | f(C) |
paul@404 | 12 | |
paul@404 | 13 | result_789 = C.clsattr |
paul@404 | 14 | result_234 = C.clsattr2 |
paul@404 | 15 | |
paul@404 | 16 | # vim: tabstop=4 expandtab shiftwidth=4 |