Method lrs::string::NoNullStr::from_mut_bytes_unchecked

Casts a byte slice to a mutable NoNullStr without checking it for validity.

Syntax

impl NoNullStr {
    unsafe fn from_mut_bytes_unchecked(bytes: &mut [u8]) -> &mut NoNullStr
}

Arguments

NameDescription
bytes

The slice to be interpreted as a NoNullStr.

Remarks

If the slice contains null bytes, the behavior is undefined.