#[non_exhaustive]pub enum A2lError {
FileOpenError {
filename: PathBuf,
ioerror: Error,
},
FileReadError {
filename: PathBuf,
ioerror: Error,
},
EmptyFileError {
filename: PathBuf,
},
InvalidBuiltinA2mlSpec {
parse_err: String,
},
TokenizerError {
tokenizer_error: TokenizerError,
},
ParserError {
parser_error: ParserError,
},
FileWriteError {
filename: PathBuf,
ioerror: Error,
},
}
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
FileOpenError
FileOpenError: An IoError that occurred while loading a file
FileReadError
FileReadError: An IoError that occurred while reading from a file
EmptyFileError
EmptyFileError: No A2lTokens found in the file
InvalidBuiltinA2mlSpec
InvalidBuiltinA2mlSpec: Parse error while processing a built-in a2ml specification
TokenizerError
TokenizerError: Failed to tokenize the input
Fields
§
tokenizer_error: TokenizerError
ParserError
ParserError: Invalid data, the file could not be parsed
Fields
§
parser_error: ParserError
FileWriteError
FileWriteError: An IoError that occurred while writing from a file
Trait Implementations§
source§impl Error for A2lError
impl Error for A2lError
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
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
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for A2lError
impl !RefUnwindSafe for A2lError
impl Send for A2lError
impl Sync for A2lError
impl Unpin for A2lError
impl !UnwindSafe for A2lError
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