What is the best practice for implementing a Drop method that can fail?
The reason I ask is because CUDA can return a failure code from device-memory-deallocation functions and other things that I'd like to call in Drop::drop. The compromise that I've gone with for RustaCUDA is to panic if Drop::drop is unable to drop a value, but to provide a separate Foo::drop function that returns the error and the un-dropped object instead, if deallocation fails.
Is there a better approach known? I suppose it could just leak the allocated memory, but that seems undesirable.