mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-19 04:51:24 +07:00
13 lines
245 B
Python
13 lines
245 B
Python
class B(object):
|
|
__slots__ = ['attr', 'b']
|
|
|
|
class C(B):
|
|
attr = 'baz'
|
|
__slots__ = ['foo', 'bar']
|
|
|
|
C.attr = 'spam'
|
|
print(C.attr)
|
|
|
|
c = C()
|
|
<warning descr="'C' object attribute 'attr' is read-only">c.attr</warning> = 'spam'
|
|
print(c.attr) |