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

Unified Diff: src/execution.cc

Issue 3613009: Addressing Mads' comments from http://codereview.chromium.org/3585010/show. (Closed)
Patch Set: Created 10 years, 2 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/execution.h ('k') | test/cctest/test-api.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/execution.cc
diff --git a/src/execution.cc b/src/execution.cc
index 54216784a7f1223ac09c98f66b53855d6a0e3c9f..68623247474fc9dbf85ea89a240dcf04ab07cd03 100644
--- a/src/execution.cc
+++ b/src/execution.cc
@@ -473,6 +473,19 @@ Handle<Object> Execution::NewDate(double time, bool* exc) {
#undef RETURN_NATIVE_CALL
+Handle<JSRegExp> Execution::NewJSRegExp(Handle<String> pattern,
+ Handle<String> flags,
+ bool* exc) {
+ Handle<Object> re_obj = RegExpImpl::CreateRegExpLiteral(
+ Handle<JSFunction>(Top::global_context()->regexp_function()),
+ pattern,
+ flags,
+ exc);
+ if (*exc) return Handle<JSRegExp>();
+ return Handle<JSRegExp>::cast(re_obj);
+}
+
+
Handle<Object> Execution::CharAt(Handle<String> string, uint32_t index) {
int int_index = static_cast<int>(index);
if (int_index < 0 || int_index >= string->length()) {
« no previous file with comments | « src/execution.h ('k') | test/cctest/test-api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698