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

Unified Diff: third_party/re2/re2/onepass.cc

Issue 1530113002: Revert of Update re2 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 | « third_party/re2/re2/nfa.cc ('k') | third_party/re2/re2/parse.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/re2/re2/onepass.cc
diff --git a/third_party/re2/re2/onepass.cc b/third_party/re2/re2/onepass.cc
index 73acdc8d4e58337c7743fae5ad9dac77f65cee28..1c4998828b500a86ad7eceac27a1cd94d3e90de4 100644
--- a/third_party/re2/re2/onepass.cc
+++ b/third_party/re2/re2/onepass.cc
@@ -53,6 +53,7 @@
#include <string.h>
#include <map>
#include "util/util.h"
+#include "util/arena.h"
#include "util/sparse_set.h"
#include "re2/prog.h"
#include "re2/stringpiece.h"
@@ -124,6 +125,9 @@
// and capture operations that must be performed. It also records
// whether a set of conditions required to finish a match at that
// point in the input rather than process the next byte.
+
+// A state in the one-pass NFA (aka DFA) - just an array of actions.
+struct OneState;
// A state in the one-pass NFA - just an array of actions indexed
// by the bytemap_[] of the next input byte. (The bytemap
@@ -331,8 +335,7 @@
if (!matched)
return false;
for (int i = 0; i < nmatch; i++)
- match[i].set(matchcap[2*i],
- static_cast<int>(matchcap[2*i+1] - matchcap[2*i]));
+ match[i].set(matchcap[2*i], matchcap[2*i+1] - matchcap[2*i]);
return true;
}
« no previous file with comments | « third_party/re2/re2/nfa.cc ('k') | third_party/re2/re2/parse.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698