Enum scan_rules::ScanErrorKind [] [src]

pub enum ScanErrorKind {
    LiteralMismatch,
    Syntax(&'static str),
    SyntaxNoMessage,
    ExpectedEnd,
    Float(ParseFloatError),
    Int(ParseIntError),
    Io(Error),
    Other(Box<Error>),
    // some variants omitted
}

Indicates the kind of error that occurred during scanning.

Variants

LiteralMismatch

Failed to match a literal pattern term.

Syntax(&'static str)

General syntax error.

SyntaxNoMessage

General syntax error.

Due to Rust issue #26448, some scanners which want to return a Syntax error cannot.

ExpectedEnd

Expected end-of-input.

Float(ParseFloatError)

Floating point parsing failed.

Int(ParseIntError)

Integer parsing failed.

Io(Error)

An IO error occurred.

Other(Box<Error>)

Some other error occurred.

Methods

impl ScanErrorKind
[src]

fn from_other<E: Into<Box<Error>>>(err: E) -> Self

Construct an Other error from some generic error value.

Trait Implementations

impl Debug for ScanErrorKind
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl Display for ScanErrorKind
[src]

fn fmt(&self, fmt: &mut Formatter) -> Result<()Error>

Formats the value using the given formatter.

impl Error for ScanErrorKind
[src]

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

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

fn description(&self) -> &str

A short description of the error. Read more