Method lrs::string::NoNullString::set_len

Truncates the string to a certain size that can be greater than the current size.

Syntax

impl<H> NoNullString<H>
    where H: Allocator,
{
    unsafe fn set_len(&mut self, size: usize) -> ()
}

Arguments

NameDescription
size

The new length of the string.

Remarks

If the new range of the string contains null bytes, the behavior is undefined.