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 #ifndef V8_OBJECTS_H_ | 5 #ifndef V8_OBJECTS_H_ |
6 #define V8_OBJECTS_H_ | 6 #define V8_OBJECTS_H_ |
7 | 7 |
8 #include <iosfwd> | 8 #include <iosfwd> |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 9509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9520 // ES6 9.5.6 | 9520 // ES6 9.5.6 |
9521 static bool DefineOwnProperty(Isolate* isolate, Handle<JSProxy> object, | 9521 static bool DefineOwnProperty(Isolate* isolate, Handle<JSProxy> object, |
9522 Handle<Object> key, PropertyDescriptor* desc, | 9522 Handle<Object> key, PropertyDescriptor* desc, |
9523 ShouldThrow should_throw); | 9523 ShouldThrow should_throw); |
9524 | 9524 |
9525 // ES6 9.5.7 | 9525 // ES6 9.5.7 |
9526 MUST_USE_RESULT static Maybe<bool> HasProperty(Isolate* isolate, | 9526 MUST_USE_RESULT static Maybe<bool> HasProperty(Isolate* isolate, |
9527 Handle<JSProxy> proxy, | 9527 Handle<JSProxy> proxy, |
9528 Handle<Name> name); | 9528 Handle<Name> name); |
9529 | 9529 |
| 9530 // ES6 9.5.8 |
| 9531 MUST_USE_RESULT static MaybeHandle<Object> GetProperty( |
| 9532 Isolate* isolate, Handle<JSProxy> proxy, Handle<Name> name, |
| 9533 Handle<Object> receiver, LanguageMode language_mode); |
| 9534 |
9530 // ES6 9.5.10 (when passed SLOPPY) | 9535 // ES6 9.5.10 (when passed SLOPPY) |
9531 MUST_USE_RESULT static Maybe<bool> DeletePropertyOrElement( | 9536 MUST_USE_RESULT static Maybe<bool> DeletePropertyOrElement( |
9532 Handle<JSProxy> proxy, Handle<Name> name, LanguageMode language_mode); | 9537 Handle<JSProxy> proxy, Handle<Name> name, LanguageMode language_mode); |
9533 | 9538 |
9534 // ES6 9.5.11 | 9539 // ES6 9.5.11 |
9535 static bool Enumerate(Isolate* isolate, Handle<JSReceiver> receiver, | 9540 static bool Enumerate(Isolate* isolate, Handle<JSReceiver> receiver, |
9536 Handle<JSProxy> proxy, KeyAccumulator* accumulator); | 9541 Handle<JSProxy> proxy, KeyAccumulator* accumulator); |
9537 | 9542 |
9538 // ES6 9.5.12 | 9543 // ES6 9.5.12 |
9539 static bool OwnPropertyKeys(Isolate* isolate, Handle<JSReceiver> receiver, | 9544 static bool OwnPropertyKeys(Isolate* isolate, Handle<JSReceiver> receiver, |
9540 Handle<JSProxy> proxy, KeyFilter filter, | 9545 Handle<JSProxy> proxy, KeyFilter filter, |
9541 Enumerability enum_policy, | 9546 Enumerability enum_policy, |
9542 KeyAccumulator* accumulator); | 9547 KeyAccumulator* accumulator); |
9543 | 9548 |
9544 MUST_USE_RESULT static MaybeHandle<Object> GetPropertyWithHandler( | |
9545 Handle<JSProxy> proxy, | |
9546 Handle<Object> receiver, | |
9547 Handle<Name> name); | |
9548 | |
9549 // If the handler defines an accessor property with a setter, invoke it. | 9549 // If the handler defines an accessor property with a setter, invoke it. |
9550 // If it defines an accessor property without a setter, or a data property | 9550 // If it defines an accessor property without a setter, or a data property |
9551 // that is read-only, fail. In all these cases set '*done' to true. | 9551 // that is read-only, fail. In all these cases set '*done' to true. |
9552 // Otherwise set it to false, in which case the return value is not | 9552 // Otherwise set it to false, in which case the return value is not |
9553 // meaningful. | 9553 // meaningful. |
9554 MUST_USE_RESULT | 9554 MUST_USE_RESULT |
9555 static Maybe<bool> SetPropertyViaPrototypesWithHandler( | 9555 static Maybe<bool> SetPropertyViaPrototypesWithHandler( |
9556 Handle<JSProxy> proxy, Handle<Object> receiver, Handle<Name> name, | 9556 Handle<JSProxy> proxy, Handle<Object> receiver, Handle<Name> name, |
9557 Handle<Object> value, ShouldThrow should_throw, bool* done); | 9557 Handle<Object> value, ShouldThrow should_throw, bool* done); |
9558 | 9558 |
(...skipping 1159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10718 } | 10718 } |
10719 return value; | 10719 return value; |
10720 } | 10720 } |
10721 }; | 10721 }; |
10722 | 10722 |
10723 | 10723 |
10724 } // NOLINT, false-positive due to second-order macros. | 10724 } // NOLINT, false-positive due to second-order macros. |
10725 } // NOLINT, false-positive due to second-order macros. | 10725 } // NOLINT, false-positive due to second-order macros. |
10726 | 10726 |
10727 #endif // V8_OBJECTS_H_ | 10727 #endif // V8_OBJECTS_H_ |
OLD | NEW |