summaryrefslogtreecommitdiffstats
path: root/tests/011/patmatch.tl
diff options
context:
space:
mode:
Diffstat (limited to 'tests/011/patmatch.tl')
-rw-r--r--tests/011/patmatch.tl7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/011/patmatch.tl b/tests/011/patmatch.tl
index 4be407fa..346b21b6 100644
--- a/tests/011/patmatch.tl
+++ b/tests/011/patmatch.tl
@@ -314,3 +314,10 @@
(2 (3 5)))
(test (when-match @(sme () () 5) 5 t) t)
+
+(test (when-match @(end 3 x) 3 x) 3)
+(test (when-match @(end (2 @x) y) '(1 2 3) (list x y)) (3 (2 3)))
+(test (when-match @(end (2 . @x) y) '(1 2 . 3) (list x y)) (3 (2 . 3)))
+
+(test (when-match @(as z @(end (2 @x) y)) '(1 2 3) (list x y z))
+ (3 (2 3) (1 2 3)))