Type Definition nom8::prelude::IResult

source ·
pub type IResult<I, O, E = Error<I>> = Result<(I, O), Err<E>>;
Expand description

Holds the result of parsing functions

It depends on the input type I, the output type O, and the error type E (by default (I, nom8::ErrorKind))

The Ok side is a pair containing the remainder of the input (the part of the data that was not parsed) and the produced value. The Err side contains an instance of nom8::Err.

Outside of the parsing code, you can use the FinishIResult::finish method to convert it to a more common result type

Trait Implementations§

Converts the parser’s IResult to a type that is more consumable by callers. Read more
Converts the parser’s IResult to a type that is more consumable by errors. Read more
Convert an Input into an appropriate Output type