pub trait AnyPeer {
// Required methods
unsafe fn from_u8(p: u8) -> Self;
unsafe fn into_u8(self) -> u8;
}Required Methods§
Sourceunsafe fn into_u8(self) -> u8
unsafe fn into_u8(self) -> u8
Dump the peer as a primitive type (u8).
§Safety
For most applications, Peers, Peer, and Me types should
be considered opaque and agnostic of their internal representation.
However, some code interpreters written for Firefly in Rust (firefly-lua)
might need the ability to save values on the virtual stack as primitive types,
and this is where this function comes in handy.
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.