Update the RegExp constructor to ECMA-262 v6 (#3538)
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
This commit is contained in:
@@ -97,22 +97,30 @@ typedef struct
|
||||
uint16_t flags; /**< RegExp flags */
|
||||
} ecma_regexp_ctx_t;
|
||||
|
||||
ecma_value_t ecma_op_create_regexp_object_from_bytecode (re_compiled_code_t *bytecode_p);
|
||||
ecma_value_t ecma_op_create_regexp_object (ecma_string_t *pattern_p, uint16_t flags);
|
||||
ecma_object_t *ecma_op_regexp_alloc (ecma_object_t *new_target_obj_p);
|
||||
ecma_value_t ecma_regexp_exec_helper (ecma_object_t *regexp_object_p,
|
||||
ecma_string_t *input_string_p);
|
||||
ecma_string_t *ecma_regexp_read_pattern_str_helper (ecma_value_t pattern_arg);
|
||||
lit_code_point_t ecma_regexp_canonicalize (lit_code_point_t ch, bool is_ignorecase);
|
||||
lit_code_point_t ecma_regexp_canonicalize_char (lit_code_point_t ch);
|
||||
ecma_value_t ecma_regexp_parse_flags (ecma_string_t *flags_str_p, uint16_t *flags_p);
|
||||
void ecma_regexp_initialize_props (ecma_object_t *re_obj_p, ecma_string_t *source_p, uint16_t flags);
|
||||
|
||||
void ecma_regexp_create_and_initialize_props (ecma_object_t *re_object_p,
|
||||
ecma_string_t *source_p,
|
||||
uint16_t flags);
|
||||
ecma_value_t ecma_regexp_replace_helper (ecma_value_t this_arg, ecma_value_t string_arg, ecma_value_t replace_arg);
|
||||
ecma_value_t ecma_regexp_search_helper (ecma_value_t regexp_arg, ecma_value_t string_arg);
|
||||
ecma_value_t ecma_regexp_split_helper (ecma_value_t this_arg, ecma_value_t string_arg, ecma_value_t limit_arg);
|
||||
ecma_value_t ecma_regexp_match_helper (ecma_value_t this_arg, ecma_value_t string_arg);
|
||||
|
||||
ecma_value_t ecma_op_regexp_exec (ecma_value_t this_arg, ecma_string_t *str_p);
|
||||
|
||||
ecma_value_t ecma_op_create_regexp_from_bytecode (ecma_object_t *regexp_obj_p, re_compiled_code_t *bc_p);
|
||||
ecma_value_t ecma_op_create_regexp_from_pattern (ecma_object_t *regexp_obj_p,
|
||||
ecma_value_t pattern_value,
|
||||
ecma_value_t flags_value);
|
||||
ecma_value_t ecma_op_create_regexp_with_flags (ecma_object_t *regexp_obj_p,
|
||||
ecma_value_t pattern_value,
|
||||
uint16_t flags);
|
||||
/**
|
||||
* @}
|
||||
* @}
|
||||
|
||||
Reference in New Issue
Block a user