micropython

Annotated tests/failure/attributes_instance_bind_function.py

288:54a2867eb465
2009-11-23 Paul Boddie Added attribute usage registration for branches where more specific attribute usage occurs, but where such usage cannot be merged back into the active usage definition for a given name. This should ensure that attributes are not forgotten because their usage was not merged and carried forward. Added more specific tests.
paul@233 1
#!/usr/bin/env python
paul@233 2
paul@233 3
def e(self, x):
paul@233 4
    return x
paul@233 5
paul@233 6
class C:
paul@233 7
    def __init__(self, e):
paul@233 8
        self.e = e
paul@233 9
paul@233 10
c = C(e)
paul@233 11
p = c.e # unbound e
paul@233 12
result_321 = p(321)
paul@233 13
paul@233 14
# vim: tabstop=4 expandtab shiftwidth=4