pub unsafe trait RepeatableTryDrop: PureTryDrop {
// Provided method
fn safe_try_drop(&mut self) -> Result<(), Self::Error> { ... }
}Expand description
Marker trait signifying that the implementing type can repeatedly call its TryDrop::try_drop
method.
§Safety
The implementor must ensure that no undefined behavior will occur when calling
TryDrop::try_drop multiple times.
Provided Methods§
Sourcefn safe_try_drop(&mut self) -> Result<(), Self::Error>
fn safe_try_drop(&mut self) -> Result<(), Self::Error>
Safely try and drop the implementing type. You can call this function multiple times.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".