Enum encode_unicode::error::InvalidUtf8Slice [] [src]

pub enum InvalidUtf8Slice {
    Utf8(InvalidUtf8),
    Codepoint(InvalidCodepoint),
    TooShort(usize),
}

Reasons why a byte slice is not valid UTF-8, in sinking precedence.

Variants

Something is certainly wrong with the first byte.

The encoded codepoint is invalid:

The slice is too short; n bytes was required.

Trait Implementations

impl Clone for InvalidUtf8Slice
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Copy for InvalidUtf8Slice
[src]

impl Debug for InvalidUtf8Slice
[src]

Formats the value using the given formatter.

impl PartialEq for InvalidUtf8Slice
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Eq for InvalidUtf8Slice
[src]

impl From<InvalidUtf8> for InvalidUtf8Slice
[src]

Performs the conversion.

impl From<InvalidCodepoint> for InvalidUtf8Slice
[src]

Performs the conversion.

impl Error for InvalidUtf8Slice
[src]

A short description of the error. Read more

The lower-level cause of this error, if any. Read more

impl Display for InvalidUtf8Slice
[src]

Formats the value using the given formatter. Read more