Index: src/runtime.cc |
diff --git a/src/runtime.cc b/src/runtime.cc |
index d183a6bd94042dc4d02e7c8cc72d4da5224c4df9..103ad06669142a525d3adeb723201443017ba39d 100644 |
--- a/src/runtime.cc |
+++ b/src/runtime.cc |
@@ -4774,10 +4774,10 @@ MaybeObject* Runtime::GetElementOrCharAt(Isolate* isolate, |
} |
if (object->IsString() || object->IsNumber() || object->IsBoolean()) { |
- return object->GetPrototype(isolate)->GetElement(index); |
+ return object->GetPrototype(isolate)->GetElement(isolate, index); |
} |
- return object->GetElement(index); |
+ return object->GetElement(isolate, index); |
} |
@@ -5904,7 +5904,7 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_GetArgumentsProperty) { |
if (index < n) { |
return frame->GetParameter(index); |
} else { |
- return isolate->initial_object_prototype()->GetElement(index); |
+ return isolate->initial_object_prototype()->GetElement(isolate, index); |
} |
} |
@@ -6679,7 +6679,7 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_NewStringWrapper) { |
SealHandleScope shs(isolate); |
ASSERT(args.length() == 1); |
CONVERT_ARG_CHECKED(String, value, 0); |
- return value->ToObject(); |
+ return value->ToObject(isolate); |
} |
@@ -7528,7 +7528,7 @@ static Object* FlatStringCompare(String* x, String* y) { |
result = (r < 0) ? Smi::FromInt(LESS) : Smi::FromInt(GREATER); |
} |
ASSERT(result == |
- StringCharacterStreamCompare(Isolate::Current()->runtime_state(), x, y)); |
+ StringCharacterStreamCompare(x->GetIsolate()->runtime_state(), x, y)); |
return result; |
} |
@@ -8771,7 +8771,7 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_Apply) { |
} |
for (int i = 0; i < argc; ++i) { |
- argv[i] = Object::GetElement(arguments, offset + i); |
+ argv[i] = Object::GetElement(isolate, arguments, offset + i); |
} |
bool threw; |
@@ -8844,7 +8844,7 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_PushWithContext) { |
extension_object = JSReceiver::cast(args[0]); |
} else { |
// Convert the object to a proper JavaScript object. |
- MaybeObject* maybe_js_object = args[0]->ToObject(); |
+ MaybeObject* maybe_js_object = args[0]->ToObject(isolate); |
if (!maybe_js_object->To(&extension_object)) { |
if (Failure::cast(maybe_js_object)->IsInternalError()) { |
HandleScope scope(isolate); |
@@ -10158,7 +10158,7 @@ static bool IterateElements(Isolate* isolate, |
} else if (receiver->HasElement(j)) { |
// Call GetElement on receiver, not its prototype, or getters won't |
// have the correct receiver. |
- element_value = Object::GetElement(receiver, j); |
+ element_value = Object::GetElement(isolate, receiver, j); |
RETURN_IF_EMPTY_HANDLE_VALUE(isolate, element_value, false); |
visitor->visit(j, element_value); |
} |
@@ -10183,7 +10183,8 @@ static bool IterateElements(Isolate* isolate, |
} else if (receiver->HasElement(j)) { |
// Call GetElement on receiver, not its prototype, or getters won't |
// have the correct receiver. |
- Handle<Object> element_value = Object::GetElement(receiver, j); |
+ Handle<Object> element_value = |
+ Object::GetElement(isolate, receiver, j); |
RETURN_IF_EMPTY_HANDLE_VALUE(isolate, element_value, false); |
visitor->visit(j, element_value); |
} |
@@ -10202,7 +10203,7 @@ static bool IterateElements(Isolate* isolate, |
while (j < n) { |
HandleScope loop_scope(isolate); |
uint32_t index = indices[j]; |
- Handle<Object> element = Object::GetElement(receiver, index); |
+ Handle<Object> element = Object::GetElement(isolate, receiver, index); |
RETURN_IF_EMPTY_HANDLE_VALUE(isolate, element, false); |
visitor->visit(index, element); |
// Skip to next different index (i.e., omit duplicates). |
@@ -13590,7 +13591,7 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_GetLanguageTagVariants) { |
Handle<Name> base = |
isolate->factory()->NewStringFromAscii(CStrVector("base")); |
for (unsigned int i = 0; i < length; ++i) { |
- MaybeObject* maybe_string = input->GetElement(i); |
+ MaybeObject* maybe_string = input->GetElement(isolate, i); |
Object* locale_id; |
if (!maybe_string->ToObject(&locale_id) || !locale_id->IsString()) { |
return isolate->Throw(isolate->heap()->illegal_argument_string()); |