pub trait UnsafeFromU8: PartialEq<u8> + Sized {
// Required methods
unsafe fn from_unsafe(_: u8) -> Self;
fn name() -> &'static str;
}
Required Methods§
Sourceunsafe fn from_unsafe(_: u8) -> Self
unsafe fn from_unsafe(_: u8) -> Self
§Safety
This function is unsafe because there is no guarantee that the value is valid
fn name() -> &'static str
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.