Implement WeakMap and WeakSet (#3328)
JerryScript-DCO-1.0-Signed-off-by: Dániel Bátyai dbatyai@inf.u-szeged.hu
This commit is contained in:
committed by
Robert Fancsik
parent
830011c033
commit
bd0cb33172
@@ -472,6 +472,42 @@ BUILTIN_ROUTINE (ECMA_BUILTIN_ID_SET,
|
||||
|
||||
#endif /* ENABLED (JERRY_ES2015_BUILTIN_SET) */
|
||||
|
||||
#if ENABLED (JERRY_ES2015_BUILTIN_WEAKMAP)
|
||||
|
||||
/* The WeakMap prototype object (23.1.3) */
|
||||
BUILTIN (ECMA_BUILTIN_ID_WEAKMAP_PROTOTYPE,
|
||||
ECMA_OBJECT_TYPE_GENERAL,
|
||||
ECMA_BUILTIN_ID_OBJECT_PROTOTYPE,
|
||||
true,
|
||||
weakmap_prototype)
|
||||
|
||||
/* The WeakMap routine (ECMA-262 v6, 23.1.1.1) */
|
||||
BUILTIN_ROUTINE (ECMA_BUILTIN_ID_WEAKMAP,
|
||||
ECMA_OBJECT_TYPE_FUNCTION,
|
||||
ECMA_BUILTIN_ID_FUNCTION_PROTOTYPE,
|
||||
true,
|
||||
weakmap)
|
||||
|
||||
#endif /* ENABLED (JERRY_ES2015_BUILTIN_WEAKMAP) */
|
||||
|
||||
#if ENABLED (JERRY_ES2015_BUILTIN_WEAKSET)
|
||||
|
||||
/* The WeakSet prototype object (23.1.3) */
|
||||
BUILTIN (ECMA_BUILTIN_ID_WEAKSET_PROTOTYPE,
|
||||
ECMA_OBJECT_TYPE_GENERAL,
|
||||
ECMA_BUILTIN_ID_OBJECT_PROTOTYPE,
|
||||
true,
|
||||
weakset_prototype)
|
||||
|
||||
/* The WeakSet routine (ECMA-262 v6, 23.1.1.1) */
|
||||
BUILTIN_ROUTINE (ECMA_BUILTIN_ID_WEAKSET,
|
||||
ECMA_OBJECT_TYPE_FUNCTION,
|
||||
ECMA_BUILTIN_ID_FUNCTION_PROTOTYPE,
|
||||
true,
|
||||
weakset)
|
||||
|
||||
#endif /* ENABLED (JERRY_ES2015_BUILTIN_WEAKSET) */
|
||||
|
||||
#if ENABLED (JERRY_ES2015)
|
||||
|
||||
/* The Symbol prototype object (ECMA-262 v6, 19.4.2.7) */
|
||||
|
||||
Reference in New Issue
Block a user