refactor(tazjin/rlox): Thread through scanner errors
... and show them to users, very crudely. Change-Id: If4491b14db1124313f6ab7e5fbfdce9fea501d11 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2193 Reviewed-by: tazjin <mail@tazj.in> Tested-by: BuildkiteCI
This commit is contained in:
parent
af793325c0
commit
36cf7bef24
3 changed files with 29 additions and 9 deletions
|
|
@ -10,6 +10,6 @@ pub struct Error {
|
|||
pub kind: ErrorKind,
|
||||
}
|
||||
|
||||
pub fn report(loc: &str, err: &Error) {
|
||||
eprintln!("[line {}] Error {}: {:?}", err.line, loc, err.kind);
|
||||
pub fn report(err: &Error) {
|
||||
eprintln!("[line {}] Error: {:?}", err.line, err.kind);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue