| Index: src/objects.cc
|
| diff --git a/src/objects.cc b/src/objects.cc
|
| index 47a61f627b817ca7d533aea305cfde7b90e4d110..5d85b13614ca6c2c64592cf769e2b7a88d5a5936 100644
|
| --- a/src/objects.cc
|
| +++ b/src/objects.cc
|
| @@ -11796,7 +11796,7 @@ MaybeHandle<Object> JSObject::SetPrototype(Handle<JSObject> object,
|
| DCHECK(new_map->prototype() == *value);
|
| JSObject::MigrateToMap(real_receiver, new_map);
|
|
|
| - if (!dictionary_elements_in_chain &&
|
| + if (from_javascript && !dictionary_elements_in_chain &&
|
| new_map->DictionaryElementsInPrototypeChainOnly()) {
|
| // If the prototype chain didn't previously have element callbacks, then
|
| // KeyedStoreICs need to be cleared to ensure any that involve this
|
|
|