micropython

tests/class_multiple_same_name_explicit_redefinition.py

782:7439ffa2b34f
2014-03-09 Paul Boddie Added another example illustrating that attributes must be defined "internally" at least once in order to be associated with a class. syspython-as-target
     1 #!/usr/bin/env python     2      3 class A:     4     x = 1     5      6 class B(A):     7     y = 2     8      9 result_2 = B.y    10     11 class B2(A):    12     z = 3    13     14 B = B2    15     16 result_1 = A.x    17 result_3 = B.z    18     19 # vim: tabstop=4 expandtab shiftwidth=4