refactor: 移除词法分析中的异常抛出
This commit is contained in:
parent
c4d9be8403
commit
2be4848735
@ -55,12 +55,6 @@ public class LexerEngine {
|
||||
TokenPrinter.print(tokens);
|
||||
/* 4. 统一报告错误 */
|
||||
report(errors);
|
||||
if (!errors.isEmpty()) {
|
||||
throw new LexicalException(
|
||||
"",
|
||||
context.getLine(), context.getCol()
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
public static void report(List<LexicalError> errors) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user