OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 894 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
905 | 905 |
906 // Property access. | 906 // Property access. |
907 MUST_USE_RESULT inline MaybeObject* GetProperty(String* key); | 907 MUST_USE_RESULT inline MaybeObject* GetProperty(String* key); |
908 MUST_USE_RESULT inline MaybeObject* GetProperty( | 908 MUST_USE_RESULT inline MaybeObject* GetProperty( |
909 String* key, | 909 String* key, |
910 PropertyAttributes* attributes); | 910 PropertyAttributes* attributes); |
911 MUST_USE_RESULT MaybeObject* GetPropertyWithReceiver( | 911 MUST_USE_RESULT MaybeObject* GetPropertyWithReceiver( |
912 Object* receiver, | 912 Object* receiver, |
913 String* key, | 913 String* key, |
914 PropertyAttributes* attributes); | 914 PropertyAttributes* attributes); |
| 915 |
| 916 static Handle<Object> GetProperty(Isolate* isolate, |
| 917 Handle<Object> object, |
| 918 Handle<Object> receiver, |
| 919 LookupResult* result, |
| 920 Handle<String> key, |
| 921 PropertyAttributes* attributes); |
| 922 |
915 MUST_USE_RESULT MaybeObject* GetProperty(Object* receiver, | 923 MUST_USE_RESULT MaybeObject* GetProperty(Object* receiver, |
916 LookupResult* result, | 924 LookupResult* result, |
917 String* key, | 925 String* key, |
918 PropertyAttributes* attributes); | 926 PropertyAttributes* attributes); |
| 927 |
919 MUST_USE_RESULT MaybeObject* GetPropertyWithDefinedGetter(Object* receiver, | 928 MUST_USE_RESULT MaybeObject* GetPropertyWithDefinedGetter(Object* receiver, |
920 JSReceiver* getter); | 929 JSReceiver* getter); |
921 | 930 |
922 inline MaybeObject* GetElement(uint32_t index); | 931 inline MaybeObject* GetElement(uint32_t index); |
923 // For use when we know that no exception can be thrown. | 932 // For use when we know that no exception can be thrown. |
924 inline Object* GetElementNoExceptionThrown(uint32_t index); | 933 inline Object* GetElementNoExceptionThrown(uint32_t index); |
925 MaybeObject* GetElementWithReceiver(Object* receiver, uint32_t index); | 934 MaybeObject* GetElementWithReceiver(Object* receiver, uint32_t index); |
926 | 935 |
927 // Return the object's prototype (might be Heap::null_value()). | 936 // Return the object's prototype (might be Heap::null_value()). |
928 Object* GetPrototype(); | 937 Object* GetPrototype(); |
(...skipping 899 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1828 // added this number can be indicated to have the backing store allocated to | 1837 // added this number can be indicated to have the backing store allocated to |
1829 // an initial capacity for holding these properties. | 1838 // an initial capacity for holding these properties. |
1830 MUST_USE_RESULT MaybeObject* NormalizeProperties( | 1839 MUST_USE_RESULT MaybeObject* NormalizeProperties( |
1831 PropertyNormalizationMode mode, | 1840 PropertyNormalizationMode mode, |
1832 int expected_additional_properties); | 1841 int expected_additional_properties); |
1833 | 1842 |
1834 // Convert and update the elements backing store to be a NumberDictionary | 1843 // Convert and update the elements backing store to be a NumberDictionary |
1835 // dictionary. Returns the backing after conversion. | 1844 // dictionary. Returns the backing after conversion. |
1836 MUST_USE_RESULT MaybeObject* NormalizeElements(); | 1845 MUST_USE_RESULT MaybeObject* NormalizeElements(); |
1837 | 1846 |
| 1847 static void UpdateMapCodeCache(Isolate* isolate, |
| 1848 Handle<JSObject> object, |
| 1849 Handle<String> name, |
| 1850 Handle<Code> code); |
| 1851 |
1838 MUST_USE_RESULT MaybeObject* UpdateMapCodeCache(String* name, Code* code); | 1852 MUST_USE_RESULT MaybeObject* UpdateMapCodeCache(String* name, Code* code); |
1839 | 1853 |
1840 // Transform slow named properties to fast variants. | 1854 // Transform slow named properties to fast variants. |
1841 // Returns failure if allocation failed. | 1855 // Returns failure if allocation failed. |
1842 MUST_USE_RESULT MaybeObject* TransformToFastProperties( | 1856 MUST_USE_RESULT MaybeObject* TransformToFastProperties( |
1843 int unused_property_fields); | 1857 int unused_property_fields); |
1844 | 1858 |
1845 // Access fast-case object properties at index. | 1859 // Access fast-case object properties at index. |
1846 inline Object* FastPropertyAt(int index); | 1860 inline Object* FastPropertyAt(int index); |
1847 inline Object* FastPropertyAtPut(int index, Object* value); | 1861 inline Object* FastPropertyAtPut(int index, Object* value); |
(...skipping 5764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7612 } else { | 7626 } else { |
7613 value &= ~(1 << bit_position); | 7627 value &= ~(1 << bit_position); |
7614 } | 7628 } |
7615 return value; | 7629 return value; |
7616 } | 7630 } |
7617 }; | 7631 }; |
7618 | 7632 |
7619 } } // namespace v8::internal | 7633 } } // namespace v8::internal |
7620 | 7634 |
7621 #endif // V8_OBJECTS_H_ | 7635 #endif // V8_OBJECTS_H_ |
OLD | NEW |