Files
openide/python/testData/inspections/PyDunderSlotsInspection/inheritedClassAttrAssignmentAndOwnWithAttrAndInheritedWithDictSlots.py
2017-05-13 00:17:45 +03:00

13 lines
187 B
Python

class B(object):
attr = 'baz'
__slots__ = ['f', 'b', '__dict__']
class C(B):
__slots__ = ['attr', 'bar']
C.attr = 'spam'
print(C.attr)
c = C()
c.attr = 'spam'
print(c.attr)