Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
GitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
regexp: add generic character types \h \v #22107
What did you do?
What did you expect to see?
What did you see instead?
It would be good if the generic character types
Sorry, but no.
It was an explicit design choice for RE2 that the Perl character classes are ASCII-only, as 'go doc regexp/syntax' says. It was also an explicit design choice to keep RE2 and Go's regexp as close as possible but not to try to keep up with Perl as Perl's syntax continues to evolve. (\h \H \v \V were added in Perl 5.10; in the case of \v, they redefined the meaning of the existing \v!)
To better align with the PCRE specification, the generic types \h \H \v \V have been added to the regexp syntax. http://www.pcre.org/original/doc/html/pcrepattern.html#genericchartypes Fixes golang#22107 Change-Id: Ide95bad8d5f566654f0c34c8c57edb257fe68336