fn strip_bom(bytes: &mut Vec<u8>) {
    if bytes.starts_with(&[0xefu8, 0xbb, 0xbf]) {
        bytes.drain(0..3);
    }
}
/// Remove BOM from the input bytes
Remove BOM from the input bytes
Remove BOM from the input bytes
fn strip_bom(bytes: &mut Vec<u8>) {
    if bytes.starts_with(&[0xefu8, 0xbb, 0xbf]) {
        bytes.drain(0..3);
    }
}
fn strip_bom ( bytes : & mut Vec < u8 > ) { if bytes . starts_with ( & [ 0xefu8 , 0xbb , 0xbf ] ) { bytes . drain ( 0 .. 3 ) ; } }
Remove BOM from the input bytes
Remove BOM from the input bytes
bytes
&mut Vec<u8>
bytes
&mut Vec<u8>