From ccb4be4da4e8aeda115b22f2a0b586a86f5e31bd Mon Sep 17 00:00:00 2001 From: Laurenz Date: Thu, 12 Aug 2021 14:54:52 +0200 Subject: Make range-end exclusive --- tests/typ/code/ops-invalid.typ | 2 +- tests/typ/code/ops.typ | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'tests/typ') diff --git a/tests/typ/code/ops-invalid.typ b/tests/typ/code/ops-invalid.typ index e1662ddd..5d371e91 100644 --- a/tests/typ/code/ops-invalid.typ +++ b/tests/typ/code/ops-invalid.typ @@ -53,7 +53,7 @@ --- { let x = 2 - for _ in 0..60 { + for _ in 0..61 { x *= 2 } // Error: 4-18 cannot repeat this string 4611686018427387904 times diff --git a/tests/typ/code/ops.typ b/tests/typ/code/ops.typ index ca328e75..d77c7503 100644 --- a/tests/typ/code/ops.typ +++ b/tests/typ/code/ops.typ @@ -163,12 +163,12 @@ // Test range operator. #let array = (1, 2, 3) -#test(1..3, array) -#test(1.. 3, array) -#test(1 ..3, array) -#test(1 .. 3, array) +#test(1..4, array) +#test(1.. 4, array) +#test(1 ..4, array) +#test(1 .. 4, array) -#test(-4..2, (-4, -3, -2, -1, 0, 1, 2)) +#test(-4..2, (-4, -3, -2, -1, 0, 1)) #test(10..5, ()) --- -- cgit v1.2.3