Struct compact_str::Utf16Error
source · [−]pub struct Utf16Error(_);
Expand description
A possible error value when converting a CompactString
from a UTF-16 byte slice.
This type is the error type for the from_utf16
method on CompactString
.
Examples
Basic usage:
// 𝄞mu<invalid>ic
let v = &[0xD834, 0xDD1E, 0x006d, 0x0075,
0xD800, 0x0069, 0x0063];
assert!(CompactString::from_utf16(v).is_err());
Trait Implementations
sourceimpl Clone for Utf16Error
impl Clone for Utf16Error
sourcefn clone(&self) -> Utf16Error
fn clone(&self) -> Utf16Error
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for Utf16Error
impl Debug for Utf16Error
sourceimpl Display for Utf16Error
impl Display for Utf16Error
impl Copy for Utf16Error
Auto Trait Implementations
impl RefUnwindSafe for Utf16Error
impl Send for Utf16Error
impl Sync for Utf16Error
impl Unpin for Utf16Error
impl UnwindSafe for Utf16Error
Blanket Implementations
sourceimpl<T> ArchivePointee for T
impl<T> ArchivePointee for T
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
sourcefn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more