When the getOwnPropertyDescriptor method was invoked the input property
descriptor was not cleared in every case. This could lead to problems when
the property descriptor is not set/modified by the getOwnPropertyDescriptor
call, resulting in a failure at a later state.
Related to this the Proxy getOwnPropertyDescriptor method incorrectly returned
"undefined" value in a single case.
JerryScript-DCO-1.0-Signed-off-by: Peter Gal pgal.usz@partner.samsung.com
Property key query for Proxy objects always returned all keys
even if no symbols were requested symbols were present in the
resulting array.
JerryScript-DCO-1.0-Signed-off-by: Peter Gal pgal.usz@partner.samsung.com
We should use the "length" property instead of the internal arraybuffer's length
JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu
separate builtin routine part to make code clear and to support 'name' property later
JerryScript-DCO-1.0-Signed-off-by: HyukWoo Park hyukwoo.park@samsung.com
During "put" with receiver the fast arrays were not converted to normal
objects to correctly set properties on it.
JerryScript-DCO-1.0-Signed-off-by: Peter Gal pgal.usz@partner.samsung.com
Tha patch also updates the [[Put]] internal method with the new steps from the ES6 standard.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
In ES2015 many builtin prototypes are no longer valid instances of their
respective classes. This change updates affected prototypes to be
regular objects as required.
JerryScript-DCO-1.0-Signed-off-by: Dániel Bátyai dbatyai@inf.u-szeged.hu
fix length property of bound function objects to be configurable (ECMA-262 v6, 19.2.4.1)
JerryScript-DCO-1.0-Signed-off-by: HyukWoo Park hyukwoo.park@samsung.com
The following methods have been implemented:
- RegExpAlloc, based on ECMA-262 v6, 21.2.3.2.1
- RegExpInitialize, based on ECMA-262 v6, 22.2.3.2.2
- RegExpCreate, based on ECMA-262 v6, 21.2.3.2.3
Co-authored-by: Robert Fancsik frobert@inf.u-szeged.hu
JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu
fix length property of function objects to be configurable (ECMA-262 v6, 19.2.4.1)
JerryScript-DCO-1.0-Signed-off-by: HyukWoo Park hyukwoo.park@samsung.com
- Internal routines of the of the proxy object are unimplemented
- For-in enumerate with proxy target is currently not supported
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
Until now arrow functions had a separate type, but most of the time they can be handled similar to single functions.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
This patch implements the get, set, has, deleteProperty, ownKeys, and construct methods of the Reflect objects. The Reflect.construct method is missing the new_target support because ecma_op_function_construct doesn't support it yet.
JerryScript-DCO-1.0-Signed-off-by: Daniella Barsony bella@inf.u-szeged.hu
Fixed:
- Global symbol access
- Array.prototype.values and Array.prototype[Symbol.iterator] must be the same function object
To test the new functionality arguments object Symbol.iterator property is added.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
Fully support @@species and SpeciesConstructor in Array and Promise builtins.
Also added partial support to TypedArrays, but a rework is needed in %TypedArray%.prototype functions' typedarray constructor, which is out of this patch's scope.
JerryScript-DCO-1.0-Signed-off-by: Daniel Balla dballa@inf.u-szeged.hu
The algorithm is based on ECMA-262 v6, 21.2.5.6
The following helper methods are also implemented:
- RegExpExec: ECMA-262 v6, 21.2.5.2.1
- AdvanceStringIndex: ECMA-262 v6, 21.2.5.2.3
JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu
This patch gives possibility to Array.prototype builtin routine optimizations.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
These two functions helps to reduce code duplication, also invokes the elimination of several ECMA_TRY_CATCH macros.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
All the basic language element guards are merged into JERRY_ES2015 macro guard.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
- The structure members have been renamed and the members got more detailed description.
- Updated the usage of the typedarray info structure in all occurrences to use absolute addressing from the underlying arraybuffer pointer.
This patch also fixes#3204.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
Here are the following changes:
- The getter and setter methods are callback based now, and we can use
them with the proper typedArray id
- The typedArray set_element and get_element methods are using memcpy now.
- There is a new struct which contains basic informations from typedArray,
and we are using this in most of the prototype methods.
- Eliminated ecma_op_typedarray_set_index_prop and
ecma_op_typedarray_get_index_prop, because these methods
also calculated the same informations which are in the new
struct, so we use the new method instead.
Co-authored-by: Robert Fancsik frobert@inf.u-szeged.hu
JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu
After this patch the ecma value collection is a resizable buffer of ecma-values where the adjacent elements are allocated next to each other.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
Since fast access mode arrays can be part of the prototype chain these objects must be handed separately.
This patch fixes#3050.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu