unexpected token
This commit is contained in:
parent
adc393be93
commit
c0692c9ffd
4
hbas.c
4
hbas.c
|
@ -321,6 +321,7 @@ typedef enum AsmError_e {
|
||||||
ErrTrailingLine,
|
ErrTrailingLine,
|
||||||
ErrNeedDirectiveAfterDot,
|
ErrNeedDirectiveAfterDot,
|
||||||
ErrDirectiveNotImplemented,
|
ErrDirectiveNotImplemented,
|
||||||
|
ErrUnexpectedToken,
|
||||||
} AsmError;
|
} AsmError;
|
||||||
char *ERRORS[] = {
|
char *ERRORS[] = {
|
||||||
"Success",
|
"Success",
|
||||||
|
@ -340,6 +341,7 @@ char *ERRORS[] = {
|
||||||
"Encountered trailing identifier after instruction",
|
"Encountered trailing identifier after instruction",
|
||||||
"Expected directive after dot",
|
"Expected directive after dot",
|
||||||
"Directive is not implemented",
|
"Directive is not implemented",
|
||||||
|
"Unexpected token",
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef struct ByteVec_s {
|
typedef struct ByteVec_s {
|
||||||
|
@ -819,6 +821,8 @@ AsmError assemble(InstHt ht, char *input, size_t len, ByteVec *out, EInfo *einfo
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
err = ErrUnexpectedToken;
|
||||||
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (size_t ii = 0; ii < holes.len; ii += 1) {
|
for (size_t ii = 0; ii < holes.len; ii += 1) {
|
||||||
|
|
Loading…
Reference in a new issue