Skip to main content

precompose_bytes_if_needed

Function precompose_bytes_if_needed 

Source
pub fn precompose_bytes_if_needed(input: &[u8]) -> Cow<'_, [u8]>
Expand description

Convert UTF-8 bytes from NFD to NFC when precomposition is active.

Non-UTF-8 byte sequences are returned unchanged (git leaves illegal sequences alone rather than dying).