micropython

Annotated tests/failure/attributes_collision.py

219:b58aae0af656
2009-05-22 Paul Boddie Removed the codedetails attribute from DataObject instances and from the structure descriptions. Added notes about argument checking for CheckFrame since the context needs to be verified where it is required. Made sure that the bool class is available since True and False are always available and their methods must also be accessible via the object table. Split various tests into separate programs with improved labelling.
paul@219 1
#!/usr/bin/env python
paul@219 2
paul@219 3
class C:
paul@219 4
    clsattr = 123
paul@219 5
paul@219 6
    def update(self, value):
paul@219 7
        self.attr = value
paul@219 8
        self.clsattr = value
paul@219 9
paul@219 10
c = C()
paul@219 11
c.update(456)
paul@219 12
paul@219 13
# vim: tabstop=4 expandtab shiftwidth=4