summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2021-02-09 06:38:49 -0800
committerKaz Kylheku <kaz@kylheku.com>2021-02-09 06:38:49 -0800
commit9e7e56bdf3ff24141efa37475eb293d0def2924b (patch)
treecf01ca8e8a5c8872a17092ef1554e54a98f09f0a
parentc423a45e7c1899401b106c93a70a82b2f3c28873 (diff)
downloadtxr-9e7e56bdf3ff24141efa37475eb293d0def2924b.tar.gz
txr-9e7e56bdf3ff24141efa37475eb293d0def2924b.tar.bz2
txr-9e7e56bdf3ff24141efa37475eb293d0def2924b.zip
matcher: get rid of undocumented @(range) op.
* share/txr/stdlib/match.tl (compile-match): Remove the rcons entry which was supposed to be already gone in version 250, and is no longer documented. (compile-range-match): Edit parameter name to remove misleading reference to rcons.
-rw-r--r--share/txr/stdlib/match.tl9
1 files changed, 4 insertions, 5 deletions
diff --git a/share/txr/stdlib/match.tl b/share/txr/stdlib/match.tl
index a1222c5a..afdf0c35 100644
--- a/share/txr/stdlib/match.tl
+++ b/share/txr/stdlib/match.tl
@@ -239,9 +239,9 @@
obj-var obj-var
guard-chain (cons guard (mappend .guard-chain elem-matches)))))
-(defun compile-range-match (rcons-expr obj-var var-list)
- (let ((from (from rcons-expr))
- (to (to rcons-expr)))
+(defun compile-range-match (range-expr obj-var var-list)
+ (let ((from (from range-expr))
+ (to (to range-expr)))
(let* ((from-match (compile-match from (gensym "from") var-list))
(to-match (compile-match to (gensym "to") var-list))
(guard (new match-guard
@@ -249,7 +249,7 @@
pure-temps (list from-match.obj-var to-match.obj-var)
pure-temp-exprs (list ^(from ,obj-var) ^(to ,obj-var)))))
(new compiled-match
- pattern rcons-expr
+ pattern range-expr
obj-var obj-var
guard-chain (cons guard (append from-match.guard-chain
to-match.guard-chain))))))
@@ -559,7 +559,6 @@
(and (compile-and-match exp obj-var var-list))
(not (compile-not-match exp obj-var var-list))
(hash (compile-hash-match exp obj-var var-list))
- (rcons (compile-range-match exp obj-var var-list))
(exprs (compile-exprs-match exp obj-var var-list))
(t (compile-predicate-match exp obj-var var-list)))
(compile-error *match-form*