MCPcopy Index your code
hub / github.com/RustPython/RustPython / utf8_first_byte

Function utf8_first_byte

crates/sre_engine/src/string.rs:315–317  ·  view source on GitHub ↗
(byte: u8, width: u32)

Source from the content-addressed store, hash-verified

313/// for width 3, and 3 bits for width 4.
314#[inline]
315const fn utf8_first_byte(byte: u8, width: u32) -> u32 {
316 (byte & (0x7F >> width)) as u32
317}
318
319/// Returns the value of `ch` updated with continuation byte `byte`.
320#[inline]

Callers 2

next_code_pointFunction · 0.70
next_code_point_reverseFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected