From e0706bc707ea6a8be86cee9fde21971cde3d7a42 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sat, 22 Nov 2025 16:34:41 -0500 Subject: Bugfix for infinite loop in text.replace("", ...) with empty string --- test/text.tm | 2 ++ 1 file changed, 2 insertions(+) (limited to 'test') diff --git a/test/text.tm b/test/text.tm index 6631b94e..094da8f8 100644 --- a/test/text.tm +++ b/test/text.tm @@ -57,6 +57,8 @@ func main() assert "xxxx".replace("x", "") == "" assert "xxxx".replace("y", "") == "xxxx" assert "One two three four five six".replace("e ", "") == "Ontwo threfour fivsix" + assert "Hello".replace("", "xxx") == "Hello" + assert "".replace("", "xxx") == "" assert amelie.has(amelie2) == yes -- cgit v1.2.3