Add support test262 $262 global object support (#4329)

Few test-cases in test262 uses a $262 object to run a few method (for example detachedArrayBuffer)

JerryScript-DCO-1.0-Signed-off-by: bence gabor kis kisbg@inf.u-szeged.hu
This commit is contained in:
kisbg
2020-12-07 17:06:15 +01:00
committed by GitHub
parent 1cb18f0ca6
commit 7cb9f808f7
5 changed files with 140 additions and 194 deletions
+8
View File
@@ -32,6 +32,7 @@ typedef enum
OPT_HELP,
OPT_VERSION,
OPT_MEM_STATS,
OPT_TEST262_OBJECT,
OPT_PARSE_ONLY,
OPT_SHOW_OP,
OPT_SHOW_RE_OP,
@@ -60,6 +61,8 @@ static const cli_opt_t main_opts[] =
.help = "print tool and library version and exit"),
CLI_OPT_DEF (.id = OPT_MEM_STATS, .longopt = "mem-stats",
.help = "dump memory statistics"),
CLI_OPT_DEF (.id = OPT_TEST262_OBJECT, .longopt = "test262-object",
.help = "create test262 object"),
CLI_OPT_DEF (.id = OPT_PARSE_ONLY, .longopt = "parse-only",
.help = "don't execute JS input"),
CLI_OPT_DEF (.id = OPT_SHOW_OP, .longopt = "show-opcodes",
@@ -180,6 +183,11 @@ main_parse_args (int argc, /**< argc */
}
break;
}
case OPT_TEST262_OBJECT:
{
arguments_p->option_flags |= OPT_FLAG_TEST262_OBJECT;
break;
}
case OPT_PARSE_ONLY:
{
arguments_p->option_flags |= OPT_FLAG_PARSE_ONLY;