Enum libafl_bolts::Error

source ·
pub enum Error {
Show 13 variants Serialize(String, ErrorBacktrace), Compression(ErrorBacktrace), EmptyOptional(String, ErrorBacktrace), KeyNotFound(String, ErrorBacktrace), Empty(String, ErrorBacktrace), IteratorEnd(String, ErrorBacktrace), NotImplemented(String, ErrorBacktrace), IllegalState(String, ErrorBacktrace), IllegalArgument(String, ErrorBacktrace), Unsupported(String, ErrorBacktrace), ShuttingDown, OsError(Error, String, ErrorBacktrace), Unknown(String, ErrorBacktrace),
}
Expand description

Main error struct for LibAFL

Variants§

§

Serialize(String, ErrorBacktrace)

Serialization error

§

Compression(ErrorBacktrace)

Compression error

§

EmptyOptional(String, ErrorBacktrace)

Optional val was supposed to be set, but isn’t.

§

KeyNotFound(String, ErrorBacktrace)

Key not in Map

§

Empty(String, ErrorBacktrace)

No elements in the current item

§

IteratorEnd(String, ErrorBacktrace)

End of iteration

§

NotImplemented(String, ErrorBacktrace)

This is not supported (yet)

§

IllegalState(String, ErrorBacktrace)

You’re holding it wrong

§

IllegalArgument(String, ErrorBacktrace)

The argument passed to this method or function is not valid

§

Unsupported(String, ErrorBacktrace)

The performed action is not supported on the current platform

§

ShuttingDown

Shutting down, not really an error.

§

OsError(Error, String, ErrorBacktrace)

OS error, wrapping a std::io::Error

§

Unknown(String, ErrorBacktrace)

Something else happened

Implementations§

source§

impl Error

source

pub fn serialize<S>(arg: S) -> Self
where S: Into<String>,

Serialization error

source

pub fn compression() -> Self

Compression error

source

pub fn empty_optional<S>(arg: S) -> Self
where S: Into<String>,

Optional val was supposed to be set, but isn’t.

source

pub fn key_not_found<S>(arg: S) -> Self
where S: Into<String>,

Key not in Map

source

pub fn empty<S>(arg: S) -> Self
where S: Into<String>,

No elements in the current item

source

pub fn iterator_end<S>(arg: S) -> Self
where S: Into<String>,

End of iteration

source

pub fn not_implemented<S>(arg: S) -> Self
where S: Into<String>,

This is not supported (yet)

source

pub fn illegal_state<S>(arg: S) -> Self
where S: Into<String>,

You’re holding it wrong

source

pub fn illegal_argument<S>(arg: S) -> Self
where S: Into<String>,

The argument passed to this method or function is not valid

source

pub fn shutting_down() -> Self

Shutting down, not really an error.

source

pub fn unsupported<S>(arg: S) -> Self
where S: Into<String>,

This operation is not supported on the current architecture or platform

source

pub fn os_error<S>(err: Error, msg: S) -> Self
where S: Into<String>,

OS error with additional message

source

pub fn last_os_error<S>(msg: S) -> Self
where S: Into<String>,

OS error from std::io::Error::last_os_error with additional message

source

pub fn unknown<S>(arg: S) -> Self
where S: Into<String>,

Something else happened

Trait Implementations§

source§

impl Debug for Error

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for Error

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Error for Error

1.30.0 · source§

fn source(&self) -> Option<&(dyn Error + 'static)>

The lower-level source of this error, if any. Read more
1.0.0 · source§

fn description(&self) -> &str

👎Deprecated since 1.42.0: use the Display impl or to_string()
1.0.0 · source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type based access to context intended for error reports. Read more
source§

impl From<BorrowError> for Error

source§

fn from(err: BorrowError) -> Self

Converts to this type from the input type.
source§

impl From<BorrowMutError> for Error

source§

fn from(err: BorrowMutError) -> Self

Converts to this type from the input type.
source§

impl From<Errno> for Error

source§

fn from(err: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

Stringify the postcard serializer error

source§

fn from(err: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

Stringify the json serializer error

source§

fn from(err: Error) -> Self

Converts to this type from the input type.
source§

impl From<Error> for Error

Create an AFL Error from io Error

source§

fn from(err: Error) -> Self

Converts to this type from the input type.
source§

impl From<FromUtf8Error> for Error

source§

fn from(err: FromUtf8Error) -> Self

Converts to this type from the input type.
source§

impl From<ParseIntError> for Error

source§

fn from(err: ParseIntError) -> Self

Converts to this type from the input type.
source§

impl From<PyErr> for Error

source§

fn from(err: PyErr) -> Self

Converts to this type from the input type.
source§

impl From<SetLoggerError> for Error

source§

fn from(err: SetLoggerError) -> Self

Converts to this type from the input type.
source§

impl From<TryFromIntError> for Error

source§

fn from(err: TryFromIntError) -> Self

Converts to this type from the input type.
source§

impl From<TryFromSliceError> for Error

source§

fn from(err: TryFromSliceError) -> Self

Converts to this type from the input type.
source§

impl From<Utf8Error> for Error

source§

fn from(err: Utf8Error) -> Self

Converts to this type from the input type.
source§

impl From<VarError> for Error

source§

fn from(err: VarError) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

§

impl Freeze for Error

§

impl !RefUnwindSafe for Error

§

impl Send for Error

§

impl Sync for Error

§

impl Unpin for Error

§

impl !UnwindSafe for Error

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<Tail, T> Prepend<T> for Tail

§

type PreprendResult = Tail

The Resulting TupleList, of an Prepend::prepend() call, including the prepended entry.
source§

fn prepend(self, value: T) -> (T, <Tail as Prepend<T>>::PreprendResult)

Prepend a value to this tuple, returning a new tuple with prepended value.
source§

impl<T> ToString for T
where T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> Ungil for T
where T: Send,