pub trait Tag: Sized {
type Buf: AsMut<[u8]> + Send;
const OFF: usize;
const MIN: usize;
// Required methods
fn make_buf() -> Self::Buf;
fn from_u8(x: u8) -> Option<Self>;
fn as_bytes(&self) -> &'static [u8] ⓘ;
}
Expand description
A type implementing Tag represents a static hash set of byte strings, with a very simple perfect hash function: every element has a unique discriminant at a common byte offset. The values of the type represent the members by this single discriminant byte; they are indices into the hash set.
Required Associated Types§
Required Associated Constants§
Required Methods§
Object Safety§
This trait is not object safe.