From 5ce263b586c5047d16ee93cc53bc3bce6f7ff12c Mon Sep 17 00:00:00 2001 From: Jonas Maier Date: Tue, 2 Jun 2026 23:52:23 +0200 Subject: fix lookahead --- test-cases/case2_positive_lookahead/script.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'test-cases/case2_positive_lookahead/script.sh') diff --git a/test-cases/case2_positive_lookahead/script.sh b/test-cases/case2_positive_lookahead/script.sh index f19441a..053461d 100644 --- a/test-cases/case2_positive_lookahead/script.sh +++ b/test-cases/case2_positive_lookahead/script.sh @@ -88,4 +88,18 @@ match x4 aaaaaaaaaaae no match x4 aaaaaaaaaaaae yes echo x4 +fun x5 { + case $1 { + (?=(a.)*e)(?=(a..)*e)(?=(a....)*e).*e { echo yes } + .* { echo no } + } +} +match x5 e yes +match x5 aaaaaaaaaaaaaaaaaaaaaaaaaaaaae no +match x5 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaae yes +match x5 a.aaaaaaaaaaaaaaaaaaaaaaaaaaa.e yes +match x5 .aaaaaaaaaaaaaaaaaaaaaaaaaaaaae no +match x5 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaae no +echo x5 + echo done -- cgit v1.2.3