Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1188)

Unified Diff: src/regexp/regexp-parser.h

Issue 2859933003: Revert of [regexp] Support unicode capture names in non-unicode patterns (Closed)
Patch Set: Fixing test Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/regexp/regexp-parser.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/regexp/regexp-parser.h
diff --git a/src/regexp/regexp-parser.h b/src/regexp/regexp-parser.h
index b34932fa00a65366c44abb5508e42ed7e22cec19..a3ef22d8b7ac8f83fe0dc777bfeb49010d780574 100644
--- a/src/regexp/regexp-parser.h
+++ b/src/regexp/regexp-parser.h
@@ -184,18 +184,11 @@ class RegExpParser BASE_EMBEDDED {
// can be reparsed.
bool ParseBackReferenceIndex(int* index_out);
- // The default behavior is to combine surrogate pairs in unicode mode and
- // don't combine them otherwise (a quantifier after a surrogate pair would
- // then apply only to the trailing surrogate). Forcing combination is required
- // when parsing capture names since they can always legally contain surrogate
- // pairs.
- enum class ScanMode { DEFAULT, FORCE_COMBINE_SURROGATE_PAIRS };
-
bool ParseClassProperty(ZoneList<CharacterRange>* result);
CharacterRange ParseClassAtom(uc16* char_class);
RegExpTree* ReportError(Vector<const char> message);
- void Advance(ScanMode mode = ScanMode::DEFAULT);
- void Advance(int dist, ScanMode mode = ScanMode::DEFAULT);
+ void Advance();
+ void Advance(int dist);
void Reset(int pos);
// Reports whether the pattern might be used as a literal search string.
@@ -311,7 +304,8 @@ class RegExpParser BASE_EMBEDDED {
bool has_more() { return has_more_; }
bool has_next() { return next_pos_ < in()->length(); }
uc32 Next();
- uc32 ReadNext(bool update_position, ScanMode mode);
+ template <bool update_position>
+ uc32 ReadNext();
FlatStringReader* in() { return in_; }
void ScanForCaptures();
« no previous file with comments | « no previous file | src/regexp/regexp-parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698