dope-sys 0.28.0

Typed operating-system call contracts
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use std::num::NonZero;

use o3::base::num::bounded;

/// Exact native buffer identity and its nonzero storage bounds.
pub trait Index: Copy + Eq {
    const ZERO: Self;

    fn advance(&mut self);
    fn offset(self, stride: NonZero<u32>) -> bounded::U64<0, { u64::MAX }>;
    fn is_within(self, capacity: NonZero<u16>) -> bool;
}