pub struct AsInt<'a> {
pub is_negative: bool,
pub little_endian: &'a [u8],
}Expand description
Canonical way to write an integer of any size.
Backward compatibility:
- The value +0 never writes bytes to the stream.
- Integers of any size (u8..u24..u128…uN) are written in a canonical form, and can be written in any order.
Fields§
§is_negative: bool§little_endian: &'a [u8]Trait Implementations§
Source§impl StableHash for AsInt<'_>
impl StableHash for AsInt<'_>
fn stable_hash<H: StableHasher>(&self, field_address: H::Addr, state: &mut H)
Auto Trait Implementations§
impl<'a> Freeze for AsInt<'a>
impl<'a> RefUnwindSafe for AsInt<'a>
impl<'a> Send for AsInt<'a>
impl<'a> Sync for AsInt<'a>
impl<'a> Unpin for AsInt<'a>
impl<'a> UnwindSafe for AsInt<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more