Register the finalizer for opaques so the Rust memory cleanup is only called if Rust has passed a Box<Opaque> back to Kotlin (and so Kotlin owns the handler and is responsible for telling Rust that the memory should be cleaned up). This is done with Cleaners already.
Register the finalizer for opaques so the Rust memory cleanup is only called if Rust has passed a
Box<Opaque>
back to Kotlin (and so Kotlin owns the handler and is responsible for telling Rust that the memory should be cleaned up). This is done with Cleaners already.