From ef9adf461863b5ef04bd13d27ad1a01e878cfed3 Mon Sep 17 00:00:00 2001 From: Tobias Schmitz Date: Fri, 9 May 2025 10:54:52 +0200 Subject: [PATCH] fix: reduce iteration limit to prevent stack overflow in test --- crates/typst-realize/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/typst-realize/src/lib.rs b/crates/typst-realize/src/lib.rs index 62760527f..f69bd3ee9 100644 --- a/crates/typst-realize/src/lib.rs +++ b/crates/typst-realize/src/lib.rs @@ -672,7 +672,7 @@ fn visit_grouping_rules<'a>( finish_innermost_grouping(s)?; i += 1; - if i > 4096 { + if i > 512 { // It seems like this case is only hit when there is a cycle between // a show rule and a grouping rule. The show rule produces content // that is matched by a grouping rule, which is then again processed