pub(crate) unsafe fn trampoline<F, R>(body: F) -> R
Expand description
Implementation of trampoline functions, which sets up a GILPool and calls F.
Panics during execution are trapped so that they don’t propagate through any outer FFI boundary.
The GIL must already be held when this is called.