OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 // | 4 // |
5 // Review notes: | 5 // Review notes: |
6 // | 6 // |
7 // - The use of macros in these inline functions may seem superfluous | 7 // - The use of macros in these inline functions may seem superfluous |
8 // but it is absolutely needed to make sure gcc generates optimal | 8 // but it is absolutely needed to make sure gcc generates optimal |
9 // code. gcc is not happy when attempting to inline too deep. | 9 // code. gcc is not happy when attempting to inline too deep. |
10 // | 10 // |
(...skipping 7004 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7015 | 7015 |
7016 bool AccessorInfo::IsCompatibleReceiver(Object* receiver) { | 7016 bool AccessorInfo::IsCompatibleReceiver(Object* receiver) { |
7017 if (!HasExpectedReceiverType()) return true; | 7017 if (!HasExpectedReceiverType()) return true; |
7018 if (!receiver->IsJSObject()) return false; | 7018 if (!receiver->IsJSObject()) return false; |
7019 return FunctionTemplateInfo::cast(expected_receiver_type()) | 7019 return FunctionTemplateInfo::cast(expected_receiver_type()) |
7020 ->IsTemplateFor(JSObject::cast(receiver)->map()); | 7020 ->IsTemplateFor(JSObject::cast(receiver)->map()); |
7021 } | 7021 } |
7022 | 7022 |
7023 | 7023 |
7024 void ExecutableAccessorInfo::clear_setter() { | 7024 void ExecutableAccessorInfo::clear_setter() { |
7025 set_setter(GetIsolate()->heap()->undefined_value(), SKIP_WRITE_BARRIER); | 7025 set_setter(*GetIsolate()->factory()->NewForeign( |
| 7026 reinterpret_cast<v8::internal::Address>( |
| 7027 reinterpret_cast<intptr_t>(nullptr)))); |
7026 } | 7028 } |
7027 | 7029 |
7028 | 7030 |
7029 template<typename Derived, typename Shape, typename Key> | 7031 template<typename Derived, typename Shape, typename Key> |
7030 void Dictionary<Derived, Shape, Key>::SetEntry(int entry, | 7032 void Dictionary<Derived, Shape, Key>::SetEntry(int entry, |
7031 Handle<Object> key, | 7033 Handle<Object> key, |
7032 Handle<Object> value) { | 7034 Handle<Object> value) { |
7033 SetEntry(entry, key, value, PropertyDetails(Smi::FromInt(0))); | 7035 SetEntry(entry, key, value, PropertyDetails(Smi::FromInt(0))); |
7034 } | 7036 } |
7035 | 7037 |
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7503 #undef READ_SHORT_FIELD | 7505 #undef READ_SHORT_FIELD |
7504 #undef WRITE_SHORT_FIELD | 7506 #undef WRITE_SHORT_FIELD |
7505 #undef READ_BYTE_FIELD | 7507 #undef READ_BYTE_FIELD |
7506 #undef WRITE_BYTE_FIELD | 7508 #undef WRITE_BYTE_FIELD |
7507 #undef NOBARRIER_READ_BYTE_FIELD | 7509 #undef NOBARRIER_READ_BYTE_FIELD |
7508 #undef NOBARRIER_WRITE_BYTE_FIELD | 7510 #undef NOBARRIER_WRITE_BYTE_FIELD |
7509 | 7511 |
7510 } } // namespace v8::internal | 7512 } } // namespace v8::internal |
7511 | 7513 |
7512 #endif // V8_OBJECTS_INL_H_ | 7514 #endif // V8_OBJECTS_INL_H_ |
OLD | NEW |