Add more skip check options for Proxy objects (#4614)
Reorganize the flags to follow the list in ES2020 section 9.5 JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
@@ -94,8 +94,9 @@ These option bits allow specializing Proxies with non-standard behaviour.
|
||||
These flags are recommended only for those trusted Proxies, whose handlers
|
||||
produce correct results.
|
||||
|
||||
- JERRY_PROXY_SKIP_GET_CHECKS - skip [[Get]] result checks
|
||||
- JERRY_PROXY_SKIP_GET_OWN_PROPERTY_CHECKS - skip [[GetOwnProperty]] result checks
|
||||
- JERRY_PROXY_SKIP_RESULT_VALIDATION - skip result validation for [[GetPrototypeOf]], [[SetPrototypeOf]], [[IsExtensible]],
|
||||
[[PreventExtensions]], [[GetOwnProperty]], [[DefineOwnProperty]], [[HasProperty]],
|
||||
[[Get]], [[Set]], [[Delete]] and [[OwnPropertyKeys]]
|
||||
|
||||
*New in version [[NEXT_RELEASE]]*.
|
||||
|
||||
@@ -5760,7 +5761,7 @@ main (void)
|
||||
|
||||
jerry_value_t target = jerry_create_object ();
|
||||
jerry_value_t handler = jerry_create_object ();
|
||||
jerry_value_t proxy = jerry_create_special_proxy (target, handler, JERRY_PROXY_SKIP_GET_CHECKS);
|
||||
jerry_value_t proxy = jerry_create_special_proxy (target, handler, JERRY_PROXY_SKIP_RESULT_VALIDATION);
|
||||
|
||||
jerry_release_value (target);
|
||||
jerry_release_value (handler);
|
||||
|
||||
Reference in New Issue
Block a user