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

Unified Diff: src/api.cc

Issue 1106633002: Wrap messages implementation in a function. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@messages_5
Patch Set: fix and rebase Created 5 years, 8 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/bootstrapper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
diff --git a/src/api.cc b/src/api.cc
index 3a89095d0b7344512dbbd6658d816f09bd851322..a81140428a0df8f8858aeaedac43e018964518c8 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -2271,8 +2271,8 @@ Maybe<int> Message::GetLineNumber(Local<Context> context) const {
PREPARE_FOR_EXECUTION_PRIMITIVE(context, "v8::Message::GetLineNumber()", int);
i::Handle<i::Object> result;
has_pending_exception =
- !CallV8HeapFunction(isolate, "GetLineNumber", Utils::OpenHandle(this))
- .ToHandle(&result);
+ !CallV8HeapFunction(isolate, "$messageGetLineNumber",
+ Utils::OpenHandle(this)).ToHandle(&result);
RETURN_ON_FAILED_EXECUTION_PRIMITIVE(int);
return Just(static_cast<int>(result->Number()));
}
@@ -2301,8 +2301,9 @@ Maybe<int> Message::GetStartColumn(Local<Context> context) const {
int);
auto self = Utils::OpenHandle(this);
i::Handle<i::Object> start_col_obj;
- has_pending_exception = !CallV8HeapFunction(isolate, "GetPositionInLine",
- self).ToHandle(&start_col_obj);
+ has_pending_exception =
+ !CallV8HeapFunction(isolate, "$messageGetPositionInLine", self)
+ .ToHandle(&start_col_obj);
RETURN_ON_FAILED_EXECUTION_PRIMITIVE(int);
return Just(static_cast<int>(start_col_obj->Number()));
}
@@ -2319,8 +2320,9 @@ Maybe<int> Message::GetEndColumn(Local<Context> context) const {
PREPARE_FOR_EXECUTION_PRIMITIVE(context, "v8::Message::GetEndColumn()", int);
auto self = Utils::OpenHandle(this);
i::Handle<i::Object> start_col_obj;
- has_pending_exception = !CallV8HeapFunction(isolate, "GetPositionInLine",
- self).ToHandle(&start_col_obj);
+ has_pending_exception =
+ !CallV8HeapFunction(isolate, "$messageGetPositionInLine", self)
+ .ToHandle(&start_col_obj);
RETURN_ON_FAILED_EXECUTION_PRIMITIVE(int);
int start = self->start_position();
int end = self->end_position();
@@ -2349,8 +2351,8 @@ MaybeLocal<String> Message::GetSourceLine(Local<Context> context) const {
PREPARE_FOR_EXECUTION(context, "v8::Message::GetSourceLine()", String);
i::Handle<i::Object> result;
has_pending_exception =
- !CallV8HeapFunction(isolate, "GetSourceLine", Utils::OpenHandle(this))
- .ToHandle(&result);
+ !CallV8HeapFunction(isolate, "$messageGetSourceLine",
+ Utils::OpenHandle(this)).ToHandle(&result);
RETURN_ON_FAILED_EXECUTION(String);
Local<String> str;
if (result->IsString()) {
« no previous file with comments | « no previous file | src/bootstrapper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698