Chromium Code Reviews| Index: src/accessors.cc |
| diff --git a/src/accessors.cc b/src/accessors.cc |
| index 6544e7197c1283f50f9e686643650589f1ff7aab..5f8c48453d8d4cf552df91c8178d3dd7ba05e329 100644 |
| --- a/src/accessors.cc |
| +++ b/src/accessors.cc |
| @@ -146,16 +146,13 @@ void Accessors::ArgumentsIteratorSetter( |
| const v8::PropertyCallbackInfo<void>& info) { |
| i::Isolate* isolate = reinterpret_cast<i::Isolate*>(info.GetIsolate()); |
| HandleScope scope(isolate); |
| - Handle<JSObject> object = Utils::OpenHandle(*info.This()); |
| - Handle<Object> value = Utils::OpenHandle(*val); |
| + Handle<JSObject> object_handle = Utils::OpenHandle(*info.This()); |
| + Handle<Object> value_handle = Utils::OpenHandle(*val); |
| + Handle<Name> name_handle = Utils::OpenHandle(*name); |
| - LookupIterator it(object, Utils::OpenHandle(*name)); |
| - CHECK_EQ(LookupIterator::ACCESSOR, it.state()); |
| - DCHECK(it.HolderIsReceiverOrHiddenPrototype()); |
| - |
| - if (Object::SetDataProperty(&it, value).is_null()) { |
| - isolate->OptionalRescheduleException(false); |
| - } |
| + JSObject::DefinePropertyOrElementIgnoreAttributes(object_handle, name_handle, |
| + value_handle, NONE) |
| + .Check(); |
|
Camillo Bruni
2015/09/10 13:59:48
I am not fully sure if and how I should check for
Jakob Kummerow
2015/09/10 14:29:20
if: yes, I think you should. (Rule of thumb: if a
|
| } |