diff --git a/collects/redex/private/matcher.rkt b/collects/redex/private/matcher.rkt index 3bbe9eb335..8d7cf6e9d6 100644 --- a/collects/redex/private/matcher.rkt +++ b/collects/redex/private/matcher.rkt @@ -1566,7 +1566,7 @@ before the pattern compiler is invoked. (cons (loop (car exp)) (loop (cdr exp)))] [(eq? the-not-hole exp) - the-hole] + the-not-hole] [(eq? the-hole exp) (if done? exp diff --git a/collects/redex/tests/tl-test.rkt b/collects/redex/tests/tl-test.rkt index ca30f77b81..0a2916bc7b 100644 --- a/collects/redex/tests/tl-test.rkt +++ b/collects/redex/tests/tl-test.rkt @@ -99,9 +99,7 @@ (define-language x (e ....)) 12))) '("....")) - - - + ;; test multiple variable non-terminals (let () (define-language lang @@ -898,6 +896,17 @@ '()) '(())) + (test (apply-reduction-relation + (reduction-relation + empty-language + (--> (in-hole (name E + (in-hole ((hide-hole hole) hole) + hole)) + number) + (in-hole E ,(add1 (term number))))) + (term (hole 2))) + (list (term (hole 3)))) + (test (apply-reduction-relation/tag-with-names (reduction-relation grammar