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 6752 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6763 PropertyAttributes AccessorInfo::property_attributes() { | 6763 PropertyAttributes AccessorInfo::property_attributes() { |
6764 return AttributesField::decode(static_cast<uint32_t>(flag()->value())); | 6764 return AttributesField::decode(static_cast<uint32_t>(flag()->value())); |
6765 } | 6765 } |
6766 | 6766 |
6767 | 6767 |
6768 void AccessorInfo::set_property_attributes(PropertyAttributes attributes) { | 6768 void AccessorInfo::set_property_attributes(PropertyAttributes attributes) { |
6769 set_flag(Smi::FromInt(AttributesField::update(flag()->value(), attributes))); | 6769 set_flag(Smi::FromInt(AttributesField::update(flag()->value(), attributes))); |
6770 } | 6770 } |
6771 | 6771 |
6772 | 6772 |
6773 bool AccessorInfo::IsCompatibleReceiver(Object* receiver) { | 6773 bool AccessorInfo::IsCompatibleReceiver(Map* map) { |
6774 Object* function_template = expected_receiver_type(); | 6774 ASSERT(HasExpectedReceiverType()); |
6775 if (!function_template->IsFunctionTemplateInfo()) return true; | 6775 return FunctionTemplateInfo::cast(expected_receiver_type()) |
6776 return FunctionTemplateInfo::cast(function_template)->IsTemplateFor(receiver); | 6776 ->IsTemplateFor(map); |
6777 } | 6777 } |
6778 | 6778 |
6779 | 6779 |
6780 void ExecutableAccessorInfo::clear_setter() { | 6780 void ExecutableAccessorInfo::clear_setter() { |
6781 set_setter(GetIsolate()->heap()->undefined_value(), SKIP_WRITE_BARRIER); | 6781 set_setter(GetIsolate()->heap()->undefined_value(), SKIP_WRITE_BARRIER); |
6782 } | 6782 } |
6783 | 6783 |
6784 | 6784 |
6785 template<typename Derived, typename Shape, typename Key> | 6785 template<typename Derived, typename Shape, typename Key> |
6786 void Dictionary<Derived, Shape, Key>::SetEntry(int entry, | 6786 void Dictionary<Derived, Shape, Key>::SetEntry(int entry, |
(...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7227 #undef READ_SHORT_FIELD | 7227 #undef READ_SHORT_FIELD |
7228 #undef WRITE_SHORT_FIELD | 7228 #undef WRITE_SHORT_FIELD |
7229 #undef READ_BYTE_FIELD | 7229 #undef READ_BYTE_FIELD |
7230 #undef WRITE_BYTE_FIELD | 7230 #undef WRITE_BYTE_FIELD |
7231 #undef NOBARRIER_READ_BYTE_FIELD | 7231 #undef NOBARRIER_READ_BYTE_FIELD |
7232 #undef NOBARRIER_WRITE_BYTE_FIELD | 7232 #undef NOBARRIER_WRITE_BYTE_FIELD |
7233 | 7233 |
7234 } } // namespace v8::internal | 7234 } } // namespace v8::internal |
7235 | 7235 |
7236 #endif // V8_OBJECTS_INL_H_ | 7236 #endif // V8_OBJECTS_INL_H_ |
OLD | NEW |