pub enum LexerError<'i> {
Show 37 variants
UnknownSegment(Rule),
LibNoName(Src<'i>),
LibNoId(Src<'i>),
RoutineNoName(Src<'i>),
RoutineUnrecognized(Src<'i>),
StatementNoInstruction(Src<'i>),
StatementNoFlag(Src<'i>),
OperatorMiscomposition(Src<'i>),
FlagWithoutValue(Src<'i>),
RegisterNoType(Src<'i>),
RegisterNoName(Src<'i>),
RegisterNameNonDecimal(Src<'i>, ParseIntError),
RegisterNoIndex(Src<'i>),
RegisterIndexNonDecimal(Src<'i>, ParseIntError, &'i str),
RegisterUnknown(Src<'i>),
CallWithoutLibName(Src<'i>),
CallWithoutRoutineName(Src<'i>),
OperandUnknown(Src<'i>, &'i str),
LiteralNoData(Src<'i>),
LiteralWrongDec(Src<'i>, &'i str, ParseIntError),
LiteralWrongHex(Src<'i>, &'i str, Error),
LiteralWrongOct(Src<'i>, &'i str, ParseIntError),
LiteralWrongBin(Src<'i>, &'i str, ParseIntError),
FloatNoWhole(Src<'i>),
FloatNoFraction(Src<'i>),
FloatWholeNotNumber(Src<'i>, ParseIntError),
FloatFractionNotNumber(Src<'i>, ParseIntError),
FloatExponentialNotNumber(Src<'i>, ParseIntError),
LiteralUnknown(Src<'i>, Rule),
ConstNoName(Src<'i>),
ConstNoValue(Src<'i>),
VarNoName(Src<'i>),
VarNoType(Src<'i>),
VarNoDescription(Src<'i>),
VarWrongDescription(Src<'i>),
VarTypeUnknown(String, Src<'i>),
ProgramAbsent,
}
Variants§
UnknownSegment(Rule)
unknown program segment {0:?}
LibNoName(Src<'i>)
library statement {0:#}
has no detectable name
{0}
LibNoId(Src<'i>)
library statement {0:#}
has no detectable lib id
{0}
RoutineNoName(Src<'i>)
routine {0:#}
has no detectable name
{0}
RoutineUnrecognized(Src<'i>)
routine {0:#}
does not start with neither .MAIN or .ROUTINE
{0}
StatementNoInstruction(Src<'i>)
label in {0:#}
is not followed by an instruction
{0}
StatementNoFlag(Src<'i>)
mnemonic is followed by non-flag rules {0}
OperatorMiscomposition(Src<'i>)
operator {0:#}
is not composed of mnemonic and flags
{0}
FlagWithoutValue(Src<'i>)
flag without flag value {0}
RegisterNoType(Src<'i>)
register operand contains no register type {0}
RegisterNoName(Src<'i>)
register operand does not specify register name {0}
RegisterNameNonDecimal(Src<'i>, ParseIntError)
register name must be encoded as a decimal number {0} details: {1}
RegisterNoIndex(Src<'i>)
register operand does not specify register index {0}
RegisterIndexNonDecimal(Src<'i>, ParseIntError, &'i str)
register index {2} is not a decimal number {0} details: {1}
RegisterUnknown(Src<'i>)
unknown register type {0}
CallWithoutLibName(Src<'i>)
call statement without library name {0}
CallWithoutRoutineName(Src<'i>)
call statement without routine name {0}
OperandUnknown(Src<'i>, &'i str)
unknown operand format {1}
inside the statement {0:#}
{0}
LiteralNoData(Src<'i>)
literal contains no data {0}
LiteralWrongDec(Src<'i>, &'i str, ParseIntError)
incorrect decimal literal {1}
{0}
details: {2}
LiteralWrongHex(Src<'i>, &'i str, Error)
incorrect hex literal {1}
{0}
details: {2}
LiteralWrongOct(Src<'i>, &'i str, ParseIntError)
incorrect oct literal {1}
{0}
details: {2}
LiteralWrongBin(Src<'i>, &'i str, ParseIntError)
incorrect bin literal {1}
{0}
details: {2}
FloatNoWhole(Src<'i>)
float literal contains no whole mantissa part {0}
FloatNoFraction(Src<'i>)
float literal contains no fractional mantissa part {0}
FloatWholeNotNumber(Src<'i>, ParseIntError)
float literal mantissa whole part is not an integer {0} details: {1}
FloatFractionNotNumber(Src<'i>, ParseIntError)
float literal mantissa fraction part is not an integer {0} details: {1}
FloatExponentialNotNumber(Src<'i>, ParseIntError)
float literal exponential part is not an integer {0} details: {1}
LiteralUnknown(Src<'i>, Rule)
unknown type of literal {1:?}
{0}
ConstNoName(Src<'i>)
constant statement has no name {0}
ConstNoValue(Src<'i>)
constant statement has no value {0}
VarNoName(Src<'i>)
input variable has no name {0}
VarNoType(Src<'i>)
input variable has no type {0}
VarNoDescription(Src<'i>)
input variable has no description {0}
VarWrongDescription(Src<'i>)
input variable description is not a string literal {0}
VarTypeUnknown(String, Src<'i>)
unknown variable type {0}
{1}
ProgramAbsent
unable to detect program code
Implementations§
Trait Implementations§
Source§impl<'i> Clone for LexerError<'i>
impl<'i> Clone for LexerError<'i>
Source§fn clone(&self) -> LexerError<'i>
fn clone(&self) -> LexerError<'i>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more