mirror of
https://github.com/golang/go
synced 2024-11-13 17:50:23 -07:00
regexp/syntax: document the upper limit of n in x{n}
Fixes #7252. LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/77990044
This commit is contained in:
parent
c790b029e6
commit
929ee59fce
@ -46,6 +46,10 @@ Repetitions:
|
||||
x{n,}? n or more x, prefer fewer
|
||||
x{n}? exactly n x
|
||||
|
||||
Implementation restriction: The counting forms x{n} etc. (but not the other
|
||||
forms x* etc.) have an upper limit of n=1000. Negative or higher explicit
|
||||
counts yield the parse error ErrInvalidRepeatSize.
|
||||
|
||||
Grouping:
|
||||
(re) numbered capturing group (submatch)
|
||||
(?P<name>re) named & numbered capturing group (submatch)
|
||||
|
Loading…
Reference in New Issue
Block a user