Sign in
android
/
platform
/
prebuilts
/
python
/
windows-x86
/
refs/heads/main
/
.
/
x86
/
Lib
/
test
/
leakers
/
test_dictself.py
blob: 99bd37d8ccf943f820ee12d5266924be07eb2892 [
file
] [
log
] [
blame
]
'''Test case for "self.__dict__ = self" circular reference bug (#1469629)'''
import
gc
class
LeakyDict
(
dict
):
pass
def
leak
():
ld
=
LeakyDict
()
ld
.
__dict__
=
ld
del
ld
gc
.
collect
();
gc
.
collect
();
gc
.
collect
()