Sindbad~EG File Manager

Current Path : /proc/2508182/root/usr/src/Python-3.12.7/Lib/test/leakers/
Upload File :
Current File : //proc/2508182/root/usr/src/Python-3.12.7/Lib/test/leakers/test_ctypes.py

# Taken from Lib/test/test_ctypes/test_keeprefs.py, PointerToStructure.test().

from ctypes import Structure, c_int, POINTER
import gc

def leak_inner():
    class POINT(Structure):
        _fields_ = [("x", c_int)]
    class RECT(Structure):
        _fields_ = [("a", POINTER(POINT))]

def leak():
    leak_inner()
    gc.collect()

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists