summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
author+merlan #flirora <uruwi@protonmail.com>2024-10-07 15:28:30 -0400
committerLaurenz <laurmaedje@gmail.com>2024-10-15 15:06:36 +0200
commit49154d844213c8abdb10480866912c1a746492e4 (patch)
tree2b06e89a68a51c3bf550dd208f0e19168d42b292 /tests
parent5220f362a5efd1a9b972cc500cd6b5c1cab4d2f2 (diff)
Fix hint for destructuring to an array with at least 1 element (#5154)
Diffstat (limited to 'tests')
-rw-r--r--tests/suite/scripting/destructuring.typ5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/suite/scripting/destructuring.typ b/tests/suite/scripting/destructuring.typ
index e70f676f..3c0c754c 100644
--- a/tests/suite/scripting/destructuring.typ
+++ b/tests/suite/scripting/destructuring.typ
@@ -137,6 +137,11 @@
// Hint: 6-20 the provided array has a length of 2, but the pattern expects at least 3 elements
#let (..a, b, c, d) = (1, 2)
+--- destructuring-let-array-too-few-elements-with-sink-1-element ---
+// Error: 6-14 not enough elements to destructure
+// Hint: 6-14 the provided array has a length of 0, but the pattern expects at least 1 element
+#let (..a, b) = ()
+
--- destructuring-let-array-bool-invalid ---
// Error: 6-12 cannot destructure boolean
#let (a, b) = true