Skip to content

Commit

Permalink
Character position for error display conventionnaly begin at 1
Browse files Browse the repository at this point in the history
  • Loading branch information
mdurero committed Jun 12, 2024
1 parent 24e4560 commit 2a4c34b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/irj_checker/irj_checker.ml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ let () =
let pos_1, pos_2 = pos.pos_loc in
Printf.eprintf "%s" (Filename.basename f);
Printf.eprintf ":(%d,%d)-(%d,%d)" pos_1.pos_lnum
(pos_1.pos_cnum - pos_1.pos_bol)
(pos_1.pos_cnum - pos_1.pos_bol + 1)
pos_2.pos_lnum
(pos_2.pos_cnum - pos_2.pos_bol);
(pos_2.pos_cnum - pos_2.pos_bol + 1);
Printf.eprintf " : %s\n" s;
exit 1
| _ ->
Expand Down

0 comments on commit 2a4c34b

Please sign in to comment.