pub enum FromOwnedUtf8WithNul {
Utf8(FromUtf8Error),
CString(FromVecWithNulError),
}Expand description
An error indicating that a nul byte was not in the expected position, or that there was invalid UTF-8.
The vector used to create a Utf8CString must have one and only one nul byte, positioned at the end.
This error is created by the Utf8CString::from_utf8_with_nul method. See its documentation for more.
Variants§
Utf8(FromUtf8Error)
The vec was not valid UTF-8.
CString(FromVecWithNulError)
The vec was not a valid C string.
Trait Implementations§
Source§impl Clone for FromOwnedUtf8WithNul
impl Clone for FromOwnedUtf8WithNul
Source§fn clone(&self) -> FromOwnedUtf8WithNul
fn clone(&self) -> FromOwnedUtf8WithNul
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FromOwnedUtf8WithNul
impl Debug for FromOwnedUtf8WithNul
Source§impl Display for FromOwnedUtf8WithNul
impl Display for FromOwnedUtf8WithNul
Source§impl From<FromUtf8Error> for FromOwnedUtf8WithNul
impl From<FromUtf8Error> for FromOwnedUtf8WithNul
Source§fn from(value: FromUtf8Error) -> FromOwnedUtf8WithNul
fn from(value: FromUtf8Error) -> FromOwnedUtf8WithNul
Converts to this type from the input type.
Source§impl From<FromVecWithNulError> for FromOwnedUtf8WithNul
impl From<FromVecWithNulError> for FromOwnedUtf8WithNul
Source§fn from(value: FromVecWithNulError) -> FromOwnedUtf8WithNul
fn from(value: FromVecWithNulError) -> FromOwnedUtf8WithNul
Converts to this type from the input type.
Source§impl PartialEq for FromOwnedUtf8WithNul
impl PartialEq for FromOwnedUtf8WithNul
impl Eq for FromOwnedUtf8WithNul
impl StructuralPartialEq for FromOwnedUtf8WithNul
Auto Trait Implementations§
impl Freeze for FromOwnedUtf8WithNul
impl RefUnwindSafe for FromOwnedUtf8WithNul
impl Send for FromOwnedUtf8WithNul
impl Sync for FromOwnedUtf8WithNul
impl Unpin for FromOwnedUtf8WithNul
impl UnwindSafe for FromOwnedUtf8WithNul
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more