summaryrefslogtreecommitdiff
path: root/tests/typ/layout
diff options
context:
space:
mode:
authorRyan Pitasky <111201305+rpitasky@users.noreply.github.com>2023-03-24 04:15:24 -0400
committerGitHub <noreply@github.com>2023-03-24 09:15:24 +0100
commit8b1852cffb9abd128da29e87598d5f37d39f4f4b (patch)
tree5488c9417b78bbffce524eafd311841f2cfc08b1 /tests/typ/layout
parent2f8802a412fb7ce888c34823a5f39f083909a9cc (diff)
Replace infinite repeat layout panic with error (#235)
When a page has auto width and there were no other constraints on the repetition width, this would previously panic. Now, there is an explicit check with a new error and test case.
Diffstat (limited to 'tests/typ/layout')
-rw-r--r--tests/typ/layout/repeat.typ5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/typ/layout/repeat.typ b/tests/typ/layout/repeat.typ
index 03642164..5663281e 100644
--- a/tests/typ/layout/repeat.typ
+++ b/tests/typ/layout/repeat.typ
@@ -37,3 +37,8 @@ A#box(width: 1fr, repeat(rect(width: 6em, height: 0.7em)))B
#set text(dir: rtl)
ريجين#box(width: 1fr, repeat(rect(width: 4em, height: 0.7em)))سون
+
+---
+// Error: 2:2-2:13 repeat with no size restrictions
+#set page(width: auto)
+#repeat(".") \ No newline at end of file