pub struct Error;Expand description
The error type which is returned from formatting a message into a stream.
This type does not support transmission of an error other than that an error occurred. Any extra information must be arranged to be transmitted through some other means.
An important thing to remember is that the type fmt::Error should not be
confused with std::io::Error or std::error::Error, which you may also
have in scope.
Examples
use std::fmt::{self, write};
let mut output = String::new();
if let Err(fmt::Error) = write(&mut output, format_args!("Hello {}!", "world")) {
panic!("An error occurred");
}RunTrait Implementations
impl Ord for Error
source
impl Ord for Error
sourceimpl PartialOrd<Error> for Error
source
impl PartialOrd<Error> for Error
sourcefn partial_cmp(&self, other: &Error) -> Option<Ordering>
source
fn partial_cmp(&self, other: &Error) -> Option<Ordering>
sourceThis method returns an ordering between self and other values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
source
fn lt(&self, other: &Rhs) -> bool
sourceThis method tests less than (for self and other) and is used by the < operator. Read more
fn le(&self, other: &Rhs) -> bool
source
fn le(&self, other: &Rhs) -> bool
sourceThis method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
impl Copy for Error
sourceimpl Eq for Error
sourceimpl StructuralEq for Error
sourceimpl StructuralPartialEq for Error
sourceAuto Trait Implementations
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
source
impl<T> BorrowMut<T> for T where
T: ?Sized,
sourcefn borrow_mut(&mut self) -> &mut T
const: unstable · source
fn borrow_mut(&mut self) -> &mut T
const: unstable · sourceMutably borrows from an owned value. Read more