summaryrefslogtreecommitdiffhomepage
path: root/tests/custom/99_bugs
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2023-07-11 12:12:21 +0200
committerJo-Philipp Wich <jo@mein.io>2023-07-12 00:38:49 +0200
commit24f1a5617ae3976313ace91970d1994a1ae7cc89 (patch)
tree8cc3508e5c2b10c34190571161f46d879016eed2 /tests/custom/99_bugs
parent9df91602e3aba0edc4771b220663f442f836f986 (diff)
source: fix source offset accounting
- When skipping the interpreter line, don't count it's newline twice - Fix reporting byte offsets beyond the end of line Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'tests/custom/99_bugs')
-rw-r--r--tests/custom/99_bugs/14_incomplete_expression_at_eof2
-rw-r--r--tests/custom/99_bugs/25_lexer_shifted_offsets2
2 files changed, 2 insertions, 2 deletions
diff --git a/tests/custom/99_bugs/14_incomplete_expression_at_eof b/tests/custom/99_bugs/14_incomplete_expression_at_eof
index 474e87c..fd0ddd6 100644
--- a/tests/custom/99_bugs/14_incomplete_expression_at_eof
+++ b/tests/custom/99_bugs/14_incomplete_expression_at_eof
@@ -3,7 +3,7 @@ buffer, the source code context line was not properly printed.
-- Expect stderr --
Syntax error: Expecting expression
-In line 1, byte 7:
+In line 2, byte 1:
`{% 1+`
^-- Near here
diff --git a/tests/custom/99_bugs/25_lexer_shifted_offsets b/tests/custom/99_bugs/25_lexer_shifted_offsets
index db10121..bb374ae 100644
--- a/tests/custom/99_bugs/25_lexer_shifted_offsets
+++ b/tests/custom/99_bugs/25_lexer_shifted_offsets
@@ -12,7 +12,7 @@ to be incorrectly shifted.
-- Expect stderr --
Error
-In line 3, byte 12:
+In line 3, byte 13:
` die("Error");`
Near here -----^