pub trait Readable: Sized {
// Required method
fn read<'a>(buf: &mut ReadBuf<'a>) -> Result<Self, ReadError>;
// Provided method
fn read_validate<'a>(buf: &mut ReadBuf<'a>) -> Result<(), ReadError> { ... }
}
Required Methods§
Provided 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.