pub unsafe trait OutputStorage<T>where
Self: Sized + OutputStorageSealed<T>,{
// Required method
unsafe fn store(self, item: T);
}
Expand description
Trait for output locations that can be passed to a chainer
§Safety
Consumers of this trait must call store
before they return again,
implementors must make sure that self
is written to when called, so users
can rely on the fact that the output location was written to. For example,
users can pass a reference to MaybeUninit
and rely on the fact that it
got initialised, and safely call assume_init
.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.