| Index: src/builtins.cc
|
| diff --git a/src/builtins.cc b/src/builtins.cc
|
| index 444f9a308b4297012940a1aa1829593a00695146..8395b31fc9787566b87100d7b0f924b9e74cff3a 100644
|
| --- a/src/builtins.cc
|
| +++ b/src/builtins.cc
|
| @@ -1186,11 +1186,17 @@ bool IsConcatSpreadable(Isolate* isolate, Handle<Object> obj) {
|
| HandleScope handle_scope(isolate);
|
| if (!obj->IsSpecObject()) return false;
|
| if (FLAG_harmony_concat_spreadable) {
|
| + // [[Get]] @@isConcatSpreadable from object. If an access check failed,
|
| + // ignore the resulting value and use the default behaviour. Otherwise,
|
| + // use the boolean value of the result.
|
| Handle<Symbol> key(isolate->factory()->is_concat_spreadable_symbol());
|
| Handle<Object> value;
|
| + bool access_check_failed;
|
| + LookupIterator it(obj, key, LookupIterator::DEFAULT);
|
| MaybeHandle<Object> maybeValue =
|
| - i::Runtime::GetObjectProperty(isolate, obj, key);
|
| - if (maybeValue.ToHandle(&value) && !value->IsUndefined()) {
|
| + Object::GetPropertyEx(&it, access_check_failed);
|
| + if (!access_check_failed && maybeValue.ToHandle(&value) &&
|
| + !value->IsUndefined()) {
|
| return value->BooleanValue();
|
| }
|
| }
|
|
|