Sign in
◑
Theme
android
/
platform
/
tools
/
idea
/
studio-master-dev
/
.
/
python
/
testData
/
inspections
/
PyDunderSlotsInspection
/
classAttrAssignmentAndSlots.py
blob: a85d00ca0e4e9d9d72e01c934cc453abbb6811be [
file
]
class
Foo
(
object
):
attr
=
'baz'
__slots__
=
[
'foo'
,
'bar'
]
Foo
.
attr
=
'spam'
print
(
Foo
.
attr
)
foo
=
Foo
()
<
warning descr
=
"'Foo' object attribute 'attr' is read-only"
>
foo
.
attr
</
warning
>
=
'spam'
print
(
foo
.
attr
)