Function regex_automata::util::wire::read_u16

source ยท
pub(crate) fn read_u16(slice: &[u8]) -> u16
Expand description

Read a u16 from the beginning of the given slice in native endian format. If the slice has fewer than 2 bytes, then this panics.

Marked as inline to speed up sparse searching which decodes integers from its automaton at search time.