[][src]Function encoding_rs::mem::copy_ascii_to_ascii

pub fn copy_ascii_to_ascii(src: &[u8], dst: &mut [u8]) -> usize

Copies ASCII from source to destination up to the first non-ASCII byte (or the end of the input if it is ASCII in its entirety).

The length of the destination buffer must be at least the length of the source buffer.

Returns the number of bytes written.

Panics

Panics if the destination buffer is shorter than stated above.