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

Unified Diff: src/isolate.cc

Issue 1126043004: Migrate error messages, part 10. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fixed and rebased Created 5 years, 7 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/ic/ic.cc ('k') | src/json.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/isolate.cc
diff --git a/src/isolate.cc b/src/isolate.cc
index 69a4f8d274d6cba4db56e5520f1b3505bc6bf8a3..f958da5b9b9663e52ea0a4bafc144e470e13b428 100644
--- a/src/isolate.cc
+++ b/src/isolate.cc
@@ -341,9 +341,8 @@ Handle<Object> Isolate::CaptureSimpleStackTrace(Handle<JSObject> error_object,
Handle<String> stackTraceLimit =
factory()->InternalizeUtf8String("stackTraceLimit");
DCHECK(!stackTraceLimit.is_null());
- Handle<Object> stack_trace_limit =
- JSObject::GetDataProperty(Handle<JSObject>::cast(error),
- stackTraceLimit);
+ Handle<Object> stack_trace_limit = JSReceiver::GetDataProperty(
+ Handle<JSObject>::cast(error), stackTraceLimit);
if (!stack_trace_limit->IsNumber()) return factory()->undefined_value();
int limit = FastD2IChecked(stack_trace_limit->Number());
limit = Max(limit, 0); // Ensure that limit is not negative.
@@ -446,7 +445,7 @@ MaybeHandle<JSObject> Isolate::CaptureAndSetSimpleStackTrace(
Handle<JSArray> Isolate::GetDetailedStackTrace(Handle<JSObject> error_object) {
Handle<Name> key_detailed = factory()->detailed_stack_trace_symbol();
Handle<Object> stack_trace =
- JSObject::GetDataProperty(error_object, key_detailed);
+ JSReceiver::GetDataProperty(error_object, key_detailed);
if (stack_trace->IsJSArray()) return Handle<JSArray>::cast(stack_trace);
if (!capture_stack_trace_for_uncaught_exceptions_) return Handle<JSArray>();
@@ -600,7 +599,7 @@ int PositionFromStackTrace(Handle<FixedArray> elements, int index) {
Handle<JSArray> Isolate::GetDetailedFromSimpleStackTrace(
Handle<JSObject> error_object) {
Handle<Name> key = factory()->stack_trace_symbol();
- Handle<Object> property = JSObject::GetDataProperty(error_object, key);
+ Handle<Object> property = JSReceiver::GetDataProperty(error_object, key);
if (!property->IsJSArray()) return Handle<JSArray>();
Handle<JSArray> simple_stack_trace = Handle<JSArray>::cast(property);
@@ -1272,19 +1271,19 @@ bool Isolate::ComputeLocationFromException(MessageLocation* target,
if (!exception->IsJSObject()) return false;
Handle<Name> start_pos_symbol = factory()->error_start_pos_symbol();
- Handle<Object> start_pos = JSObject::GetDataProperty(
+ Handle<Object> start_pos = JSReceiver::GetDataProperty(
Handle<JSObject>::cast(exception), start_pos_symbol);
if (!start_pos->IsSmi()) return false;
int start_pos_value = Handle<Smi>::cast(start_pos)->value();
Handle<Name> end_pos_symbol = factory()->error_end_pos_symbol();
- Handle<Object> end_pos = JSObject::GetDataProperty(
+ Handle<Object> end_pos = JSReceiver::GetDataProperty(
Handle<JSObject>::cast(exception), end_pos_symbol);
if (!end_pos->IsSmi()) return false;
int end_pos_value = Handle<Smi>::cast(end_pos)->value();
Handle<Name> script_symbol = factory()->error_script_symbol();
- Handle<Object> script = JSObject::GetDataProperty(
+ Handle<Object> script = JSReceiver::GetDataProperty(
Handle<JSObject>::cast(exception), script_symbol);
if (!script->IsScript()) return false;
@@ -1301,7 +1300,7 @@ bool Isolate::ComputeLocationFromStackTrace(MessageLocation* target,
if (!exception->IsJSObject()) return false;
Handle<Name> key = factory()->stack_trace_symbol();
Handle<Object> property =
- JSObject::GetDataProperty(Handle<JSObject>::cast(exception), key);
+ JSReceiver::GetDataProperty(Handle<JSObject>::cast(exception), key);
if (!property->IsJSArray()) return false;
Handle<JSArray> simple_stack_trace = Handle<JSArray>::cast(property);
« no previous file with comments | « src/ic/ic.cc ('k') | src/json.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698