File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 114
114
(define ((term-match/single/proc form-name lang ps0 cps rhss) term)
115
115
(let loop ([ps ps0] [cps cps] [rhss rhss])
116
116
(if (null? ps)
117
- (redex-error form-name
118
- (if (null? (cdr ps0))
119
- (format "term ~s does not match pattern ~s " term (car ps0))
120
- (format "no patterns matched ~s " term)))
117
+ (if (null? (cdr ps0))
118
+ (redex-error form-name "term ~s does not match pattern ~s " term (car ps0))
119
+ (redex-error form-name "no patterns matched ~s " term))
121
120
(let ([match (match-pattern (car cps) term)])
122
121
(if match
123
122
(begin
Original file line number Diff line number Diff line change 583
583
(term (number_1 6 ) #:lang L))
584
584
'(5 6 )))
585
585
586
+ (test (with-handlers ([exn:fail:redex? exn-message])
587
+ (redex-let empty-language ([~PATTERN 'TERM ])
588
+ "no error " ))
589
+ #rx"pattern ~PATTERN " )
590
+
586
591
;; make sure the "before underscore" check works (no syntax error)
587
592
(let ()
588
593
(define-extended-language L2 empty-language [(τ υ) whatever])
You can’t perform that action at this time.
0 commit comments