Fix Redex variable-not-otherwise-mentioned bug.
And add a test to keep it from happening again.
This commit is contained in:
parent
2873ba700f
commit
e02d425aa5
|
@ -242,7 +242,9 @@
|
||||||
[else (loop sub-pat)]))
|
[else (loop sub-pat)]))
|
||||||
sub-pats)]
|
sub-pats)]
|
||||||
[(? (compose not pair?))
|
[(? (compose not pair?))
|
||||||
(set pat)])))
|
(if (symbol? pat)
|
||||||
|
(set pat)
|
||||||
|
(set))])))
|
||||||
(nt-rhs the-nt)))
|
(nt-rhs the-nt)))
|
||||||
lang)))
|
lang)))
|
||||||
|
|
||||||
|
|
|
@ -80,7 +80,7 @@
|
||||||
|
|
||||||
;; test variable-not-otherwise-mentioned
|
;; test variable-not-otherwise-mentioned
|
||||||
(define-language VarMentioned
|
(define-language VarMentioned
|
||||||
(mention a b c x y z)
|
(mention a b c x y z 2 #f #\c (vec 1 2))
|
||||||
(var variable-not-otherwise-mentioned))
|
(var variable-not-otherwise-mentioned))
|
||||||
|
|
||||||
(try-it 20 VarMentioned var)
|
(try-it 20 VarMentioned var)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user