mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 532254: Give TCF_FUN_PARAM_EVAL a distinct value. r=mrbkap
Regression test included.
This commit is contained in:
parent
dbab286e15
commit
ff9fa29631
@ -257,7 +257,6 @@ struct JSTreeContext { /* tree context for semantic checks */
|
||||
#define TCF_NO_SCRIPT_RVAL 0x4000 /* API caller does not want result value
|
||||
from global script */
|
||||
#define TCF_HAS_SHARPS 0x8000 /* source contains sharp defs or uses */
|
||||
#define TCF_FUN_PARAM_EVAL 0x10000 /* function has parameter named 'eval' */
|
||||
|
||||
/*
|
||||
* Set when parsing a declaration-like destructuring pattern. This
|
||||
@ -286,7 +285,10 @@ struct JSTreeContext { /* tree context for semantic checks */
|
||||
* the use of 'with'. See also TSF_STRICT_MODE_CODE,
|
||||
* JSScript::strictModeCode, and JSREPORT_STRICT_ERROR.
|
||||
*/
|
||||
#define TCF_STRICT_MODE_CODE 0x40000
|
||||
#define TCF_STRICT_MODE_CODE 0x40000
|
||||
|
||||
/* Function has parameter named 'eval'. */
|
||||
#define TCF_FUN_PARAM_EVAL 0x80000
|
||||
|
||||
/*
|
||||
* Flags to propagate out of the blocks.
|
||||
|
@ -15,4 +15,5 @@ script 12.14.1.js
|
||||
script 13.1.js
|
||||
script B.1.1.js
|
||||
script B.1.2.js
|
||||
script regress-532254.js
|
||||
script regress-532041.js
|
||||
|
13
js/src/tests/ecma_5/strict/regress-532254.js
Normal file
13
js/src/tests/ecma_5/strict/regress-532254.js
Normal file
@ -0,0 +1,13 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
|
||||
/*
|
||||
* Any copyright is dedicated to the Public Domain.
|
||||
* http://creativecommons.org/licenses/publicdomain/
|
||||
*/
|
||||
|
||||
assertEq(testLenientAndStrict('function f(eval,[x]){}',
|
||||
parsesSuccessfully,
|
||||
parseRaisesException(SyntaxError)),
|
||||
true);
|
||||
|
||||
reportCompare(true, true);
|
Loading…
Reference in New Issue
Block a user