diff options
author | Leo Tenenbaum <pommicket@gmail.com> | 2020-04-23 14:01:20 -0400 |
---|---|---|
committer | Leo Tenenbaum <pommicket@gmail.com> | 2020-04-23 14:01:20 -0400 |
commit | f7bfb9492ab546e886fd40bda1a0ab25fcb05247 (patch) | |
tree | 1ec694390050cc3eb21009963d40dc6655c0a5fa /err.c | |
parent | 4062e5c965bc04ec9654d82526e5e785f7f45d03 (diff) |
fixed error printing problem, added new test: use
Diffstat (limited to 'err.c')
-rw-r--r-- | err.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -83,6 +83,7 @@ static void err_fprint(ErrCtx *ctx, const char *fmt, ...) { } static void print_location_highlight(FILE *out, Location where) { + assert(where.end >= where.start); File *f = where.file; ErrCtx *ctx = f->ctx; if (where.start == 0 && where.end == 0) { err_fprint(ctx, "\n"); return; } /* null location */ |