diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-01-27 22:47:00 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-01-27 22:47:00 -0800 |
commit | 600ec3af3f742f361164aac53cda6b02b90e5173 (patch) | |
tree | a5d138e4b87191572216308a7ebab7eb673c4954 | |
parent | 1e7a05992ca4cc652d61c76ed4c06f8584e1d1b1 (diff) | |
download | txr-600ec3af3f742f361164aac53cda6b02b90e5173.tar.gz txr-600ec3af3f742f361164aac53cda6b02b90e5173.tar.bz2 txr-600ec3af3f742f361164aac53cda6b02b90e5173.zip |
matcher: remove superflous test-expr in hash op.
* share/txr/stdlib/match.tl (compile-hash-match): In the
trivial key case, we are wastefully installing the same
expression as both a guard in the guard-chain and as a
test-expr. We should not be frobbing vm.test-expr.
-rw-r--r-- | share/txr/stdlib/match.tl | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/share/txr/stdlib/match.tl b/share/txr/stdlib/match.tl index 5d67ef6a..3e254f65 100644 --- a/share/txr/stdlib/match.tl +++ b/share/txr/stdlib/match.tl @@ -391,8 +391,6 @@ (push vm.obj-var vm.vars) (push ^(gethash ,obj-var ,key-var-sym ,hash-alt-val) vm.var-exprs) - (set vm.test-expr ^(and (neq ,vm.obj-var ,hash-alt-val) - ,vm.test-expr)) vm)) ((and key-pat-p val-pat-p) (set need-alist-p t) |