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

Unified Diff: src/parser.cc

Issue 42007: Fixed a few more incompatibilities (Closed)
Patch Set: Created 11 years, 9 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 | « src/messages.js ('k') | src/regexp-delay.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parser.cc
diff --git a/src/parser.cc b/src/parser.cc
index 43fd012f0c4fd9b8a8c4470629d7ce3da7628bc4..12f1781a76e9c2d10a0bb0f277f85c1ec5a1189b 100644
--- a/src/parser.cc
+++ b/src/parser.cc
@@ -4177,10 +4177,8 @@ bool RegExpParser::ParseIntervalQuantifier(int* min_out, int* max_out) {
STATIC_CHECK(('a' ^ 'A') == 0x20);
uc32 RegExpParser::ParseControlLetterEscape() {
- if (!has_more()) {
- ReportError(CStrVector("\\c at end of pattern"));
- return '\0';
- }
+ if (!has_more())
+ return 'c';
uc32 letter = current() & ~(0x20); // Collapse upper and lower case letters.
if (letter < 'A' || 'Z' < letter) {
// Non-spec error-correction: "\c" followed by non-control letter is
« no previous file with comments | « src/messages.js ('k') | src/regexp-delay.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698