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

Unified Diff: test/cctest/test-regexp.cc

Issue 13618: * Delayed compilation of irregexps until use-time, and specialize on char type. (Closed)
Patch Set: Created 12 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
« src/regexp-macro-assembler-ia32.cc ('K') | « src/regexp-macro-assembler-ia32.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-regexp.cc
diff --git a/test/cctest/test-regexp.cc b/test/cctest/test-regexp.cc
index 4bd3222c11e3d6d7a36c45e023dcd181c5cb903c..b3e54f38f3f19d29abdda1c8516f4b13771bb48b 100644
--- a/test/cctest/test-regexp.cc
+++ b/test/cctest/test-regexp.cc
@@ -355,7 +355,7 @@ TEST(CharacterClassEscapes) {
}
-static RegExpNode* Compile(const char* input, bool multiline) {
+static RegExpNode* Compile(const char* input, bool multiline, bool is_ascii) {
V8::Initialize(NULL);
FlatStringReader reader(CStrVector(input));
RegExpParseResult result;
@@ -363,17 +363,18 @@ static RegExpNode* Compile(const char* input, bool multiline) {
return NULL;
RegExpNode* node = NULL;
Handle<String> pattern = Factory::NewStringFromUtf8(CStrVector(input));
- RegExpEngine::Compile(&result, &node, false, multiline, pattern);
+ RegExpEngine::Compile(&result, &node, false, multiline, pattern, is_ascii);
return node;
}
static void Execute(const char* input,
bool multiline,
+ bool is_ascii,
bool dot_output = false) {
v8::HandleScope scope;
ZoneScope zone_scope(DELETE_ON_EXIT);
- RegExpNode* node = Compile(input, multiline);
+ RegExpNode* node = Compile(input, multiline, is_ascii);
USE(node);
#ifdef DEBUG
if (dot_output) {
@@ -1130,7 +1131,7 @@ TEST(LatinCanonicalize) {
TEST(SimplePropagation) {
v8::HandleScope scope;
ZoneScope zone_scope(DELETE_ON_EXIT);
- RegExpNode* node = Compile("(a|^b|c)", false);
+ RegExpNode* node = Compile("(a|^b|c)", false, true);
CHECK(node->info()->follows_start_interest);
}
@@ -1300,5 +1301,5 @@ TEST(CharClassDifference) {
TEST(Graph) {
V8::Initialize(NULL);
- Execute("(?=[d#.])", false, true);
+ Execute("(?=[d#.])", false, true, true);
}
« src/regexp-macro-assembler-ia32.cc ('K') | « src/regexp-macro-assembler-ia32.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698