pub fn block_on_local<T>(
env: &mut JNIEnv<'_>,
context: &str,
fut: impl Future<Output = T>,
) -> Option<T>Expand description
Block on a future that borrows local (non-’static) data, panic-safe.
Unlike block_on_jni, the future may borrow from the caller’s stack;
it runs on the shared JNI runtime via Handle::block_on semantics.
Must NOT be called from within an existing Tokio runtime thread
(that would deadlock); in that case it falls back to a fresh
single-threaded runtime.