Double plusses in regex
I have seen several regular expressions that have two plusses in a row. What exactly does this mean? One or more of one or more of the pattern. If the pattern matches in 开发者_开发知识库the first place, why would the second match be necessary?
Examples:
[a-zA-Z0-9_]++
[^/.,;?]++
They're called possessive quantifiers.
精彩评论