diff --git a/regexp.rkt b/regexp.rkt index 1d585b7..5eda021 100644 --- a/regexp.rkt +++ b/regexp.rkt @@ -106,7 +106,7 @@ (define-for-syntax (group-error str reason) (raise-argument-error errloc-key - (format "Valid regexp pattern (contains unmatched ~a)" reason) + (format "Valid regexp pattern (unmatched ~a)" reason) str)) ;; Dispatch for counting groups diff --git a/scribblings/trivial.scrbl b/scribblings/trivial.scrbl index bf460e7..333b5e4 100644 --- a/scribblings/trivial.scrbl +++ b/scribblings/trivial.scrbl @@ -70,6 +70,7 @@ In other words, the result is one string for the matched substring and an unknow (U #f (List String String))) (ann (regexp-match: #"(la(m*)bda)" #"lam") (U #f (List Bytes Bytes Bytes))) + (regexp-match: "(bad))group" "") ] @emph{Note:} the regular expression @racket{|} operator is not currently supported because it can nullify some groups.