OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 2200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2211 bool continue_search); | 2211 bool continue_search); |
2212 PropertyAttributes GetPropertyAttributeWithFailedAccessCheck( | 2212 PropertyAttributes GetPropertyAttributeWithFailedAccessCheck( |
2213 Object* receiver, | 2213 Object* receiver, |
2214 LookupResult* result, | 2214 LookupResult* result, |
2215 Name* name, | 2215 Name* name, |
2216 bool continue_search); | 2216 bool continue_search); |
2217 PropertyAttributes GetElementAttributeWithReceiver(JSReceiver* receiver, | 2217 PropertyAttributes GetElementAttributeWithReceiver(JSReceiver* receiver, |
2218 uint32_t index, | 2218 uint32_t index, |
2219 bool continue_search); | 2219 bool continue_search); |
2220 | 2220 |
| 2221 // Retrieves an AccessorPair property from the given object. Might return |
| 2222 // undefined if the property doesn't exist or is of a different kind. |
| 2223 static Handle<Object> GetAccessor(Handle<JSObject> object, |
| 2224 Handle<Name> name, |
| 2225 AccessorComponent component); |
| 2226 |
| 2227 // Defines an AccessorPair property on the given object. |
| 2228 // TODO(mstarzinger): Rename to SetAccessor() and return empty handle on |
| 2229 // exception instead of letting callers check for scheduled exception. |
2221 static void DefineAccessor(Handle<JSObject> object, | 2230 static void DefineAccessor(Handle<JSObject> object, |
2222 Handle<Name> name, | 2231 Handle<Name> name, |
2223 Handle<Object> getter, | 2232 Handle<Object> getter, |
2224 Handle<Object> setter, | 2233 Handle<Object> setter, |
2225 PropertyAttributes attributes, | 2234 PropertyAttributes attributes, |
2226 v8::AccessControl access_control = v8::DEFAULT); | 2235 v8::AccessControl access_control = v8::DEFAULT); |
2227 | 2236 |
2228 MaybeObject* LookupAccessor(Name* name, AccessorComponent component); | 2237 // Defines an AccessorInfo property on the given object. |
2229 | |
2230 static Handle<Object> SetAccessor(Handle<JSObject> object, | 2238 static Handle<Object> SetAccessor(Handle<JSObject> object, |
2231 Handle<AccessorInfo> info); | 2239 Handle<AccessorInfo> info); |
2232 | 2240 |
2233 // Used from Object::GetProperty(). | 2241 // Used from Object::GetProperty(). |
2234 MUST_USE_RESULT MaybeObject* GetPropertyWithFailedAccessCheck( | 2242 MUST_USE_RESULT MaybeObject* GetPropertyWithFailedAccessCheck( |
2235 Object* receiver, | 2243 Object* receiver, |
2236 LookupResult* result, | 2244 LookupResult* result, |
2237 Name* name, | 2245 Name* name, |
2238 PropertyAttributes* attributes); | 2246 PropertyAttributes* attributes); |
2239 MUST_USE_RESULT MaybeObject* GetPropertyWithInterceptor( | 2247 MUST_USE_RESULT MaybeObject* GetPropertyWithInterceptor( |
(...skipping 7992 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10232 } else { | 10240 } else { |
10233 value &= ~(1 << bit_position); | 10241 value &= ~(1 << bit_position); |
10234 } | 10242 } |
10235 return value; | 10243 return value; |
10236 } | 10244 } |
10237 }; | 10245 }; |
10238 | 10246 |
10239 } } // namespace v8::internal | 10247 } } // namespace v8::internal |
10240 | 10248 |
10241 #endif // V8_OBJECTS_H_ | 10249 #endif // V8_OBJECTS_H_ |
OLD | NEW |