Skip to main content

PyClassWithFreeList

Trait PyClassWithFreeList 

Source
pub trait PyClassWithFreeList: PyClass + Sealed {
    // Required method
    fn get_free_list(py: Python<'_>) -> &'static Mutex<PyObjectFreeList>;
}
Expand description

Implements a freelist.

Do not implement this trait manually. Instead, use #[pyclass(freelist = N)] on a Rust struct to implement it.

Required Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

⚠️ Internal Docs ⚠️ Not Public API 👉 Official Docs Here