mirror of
https://github.com/tc39/test262.git
synced 2025-07-27 16:04:36 +02:00
Class Fields: features corrections
This commit is contained in:
parent
ad446cae7d
commit
192c8fd4f6
@ -13,7 +13,7 @@ info: |
|
|||||||
It is a Syntax Error if the UnaryExpression is contained in strict mode code and the derived UnaryExpression is PrimaryExpression : IdentifierReference , MemberExpression : MemberExpression.PrivateName , or CallExpression : CallExpression.PrivateName .
|
It is a Syntax Error if the UnaryExpression is contained in strict mode code and the derived UnaryExpression is PrimaryExpression : IdentifierReference , MemberExpression : MemberExpression.PrivateName , or CallExpression : CallExpression.PrivateName .
|
||||||
|
|
||||||
It is a Syntax Error if the derived UnaryExpression is PrimaryExpression : CoverParenthesizedExpressionAndArrowParameterList and CoverParenthesizedExpressionAndArrowParameterList ultimately derives a phrase that, if used in place of UnaryExpression, would produce a Syntax Error according to these rules. This rule is recursively applied.
|
It is a Syntax Error if the derived UnaryExpression is PrimaryExpression : CoverParenthesizedExpressionAndArrowParameterList and CoverParenthesizedExpressionAndArrowParameterList ultimately derives a phrase that, if used in place of UnaryExpression, would produce a Syntax Error according to these rules. This rule is recursively applied.
|
||||||
features: [class, class-fields-private]
|
features: [class, class-fields-private, class-fields-public]
|
||||||
negative:
|
negative:
|
||||||
type: SyntaxError
|
type: SyntaxError
|
||||||
phase: parse
|
phase: parse
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-arrow-fnc-
|
path: language/statements/class/fields-arrow-fnc-
|
||||||
name: arrow function expression
|
name: arrow function expression
|
||||||
features: [arrow-function]
|
features: [arrow-function, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,11 +5,12 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-comp-name-
|
path: language/statements/class/fields-comp-name-
|
||||||
name: computed ClassElementName
|
name: computed ClassElementName
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
|
||||||
var x = "string";
|
var x = "string";
|
||||||
class C {
|
class C {
|
||||||
static [x] = /*{ initializer }*/;
|
[x] = /*{ initializer }*/;
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-equality-
|
path: language/statements/class/fields-equality-
|
||||||
name: equality expression
|
name: equality expression
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-literal-name-
|
path: language/statements/class/fields-literal-name-
|
||||||
name: literal ClassElementName
|
name: literal ClassElementName
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-static-comp-name-
|
path: language/statements/class/fields-static-comp-name-
|
||||||
name: static computed ClassElementName
|
name: static computed ClassElementName
|
||||||
|
features: [class, class-static-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-static-literal-
|
path: language/statements/class/fields-static-literal-
|
||||||
name: static literal ClassElementName
|
name: static literal ClassElementName
|
||||||
|
features: [class, class-static-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-static-private-
|
path: language/statements/class/fields-static-private-
|
||||||
name: static PrivateName
|
name: static PrivateName
|
||||||
|
features: [class, class-static-fields-private]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-static-string-literal-name-
|
path: language/statements/class/fields-static-string-literal-name-
|
||||||
name: static string literal ClassElementName
|
name: static string literal ClassElementName
|
||||||
|
features: [class, class-static-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-string-literal-name-
|
path: language/statements/class/fields-string-literal-name-
|
||||||
name: string literal ClassElementName
|
name: string literal ClassElementName
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-ternary-
|
path: language/statements/class/fields-ternary-
|
||||||
name: ternary expression
|
name: ternary expression
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/statements/class/fields-typeof-
|
path: language/statements/class/fields-typeof-
|
||||||
name: typeof expression
|
name: typeof expression
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-arrow-fnc-
|
path: language/expressions/class/fields-arrow-fnc-
|
||||||
name: arrow function expression
|
name: arrow function expression
|
||||||
features: [arrow-function]
|
features: [arrow-function, class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-comp-name-
|
path: language/expressions/class/fields-comp-name-
|
||||||
name: computed ClassElementName
|
name: computed ClassElementName
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-equality-
|
path: language/expressions/class/fields-equality-
|
||||||
name: equality expression
|
name: equality expression
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-literal-name-
|
path: language/expressions/class/fields-literal-name-
|
||||||
name: literal ClassElementName
|
name: literal ClassElementName
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-static-comp-name-
|
path: language/expressions/class/fields-static-comp-name-
|
||||||
name: static computed ClassElementName
|
name: static computed ClassElementName
|
||||||
|
features: [class, class-static-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-static-literal-
|
path: language/expressions/class/fields-static-literal-
|
||||||
name: static literal ClassElementName
|
name: static literal ClassElementName
|
||||||
|
features: [class, class-static-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-static-private-
|
path: language/expressions/class/fields-static-private-
|
||||||
name: static PrivateName
|
name: static PrivateName
|
||||||
|
features: [class, class-static-fields-private]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-static-string-literal-name-
|
path: language/expressions/class/fields-static-string-literal-name-
|
||||||
name: static string literal ClassElementName
|
name: static string literal ClassElementName
|
||||||
|
features: [class, class-static-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-string-literal-name-
|
path: language/expressions/class/fields-string-literal-name-
|
||||||
name: string literal ClassElementName
|
name: string literal ClassElementName
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-ternary-
|
path: language/expressions/class/fields-ternary-
|
||||||
name: ternary expression
|
name: ternary expression
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-class-definitions-static-semantics-early-errors
|
esid: sec-class-definitions-static-semantics-early-errors
|
||||||
path: language/expressions/class/fields-typeof-
|
path: language/expressions/class/fields-typeof-
|
||||||
name: typeof expression
|
name: typeof expression
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
throw "Test262: This statement should not be evaluated.";
|
throw "Test262: This statement should not be evaluated.";
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-direct-
|
path: language/statements/class/fields-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-indirect-
|
path: language/statements/class/fields-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-direct-
|
path: language/expressions/class/fields-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-indirect-
|
path: language/expressions/class/fields-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-direct-
|
path: language/statements/class/fields-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-indirect-
|
path: language/statements/class/fields-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-direct-
|
path: language/expressions/class/fields-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-indirect-
|
path: language/expressions/class/fields-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
@ -7,9 +7,8 @@ path: language/statements/class/fields-derived-cls-direct-
|
|||||||
name: direct eval
|
name: direct eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
class A {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
class A {}
|
||||||
class C extends A {
|
class C extends A {
|
||||||
x = eval('executed = true; /*{ initializer }*/;');
|
x = eval('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
@ -7,9 +7,8 @@ path: language/statements/class/fields-derived-cls-indirect-
|
|||||||
name: indirect eval
|
name: indirect eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
class A {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
class A {}
|
||||||
class C extends A {
|
class C extends A {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
@ -7,9 +7,8 @@ path: language/expressions/class/fields-derived-cls-direct-
|
|||||||
name: direct eval
|
name: direct eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var A = class {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
var A = class {}
|
||||||
var C = class extends A {
|
var C = class extends A {
|
||||||
x = eval('executed = true; /*{ initializer }*/;');
|
x = eval('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
@ -7,9 +7,8 @@ path: language/expressions/class/fields-derived-cls-indirect-
|
|||||||
name: indirect eval
|
name: indirect eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var A = class {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
var A = class {}
|
||||||
var C = class extends A {
|
var C = class extends A {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
@ -7,9 +7,8 @@ path: language/statements/class/fields-derived-cls-direct-
|
|||||||
name: direct eval
|
name: direct eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
class A {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
class A {}
|
||||||
class C extends A {
|
class C extends A {
|
||||||
x = eval('executed = true; /*{ initializer }*/;');
|
x = eval('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
@ -7,9 +7,8 @@ path: language/statements/class/fields-derived-cls-indirect-
|
|||||||
name: indirect eval
|
name: indirect eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
class A {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
class A {}
|
||||||
class C extends A {
|
class C extends A {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
@ -7,12 +7,11 @@ path: language/expressions/class/fields-derived-cls-direct-
|
|||||||
name: direct eval
|
name: direct eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var A = class {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
var A = class {}
|
||||||
var C = class extends A {
|
var C = class extends A {
|
||||||
x = eval('executed = true; /*{ initializer }*/;');
|
x = eval('executed = true; /*{ initializer }*/;');
|
||||||
}
|
};
|
||||||
|
|
||||||
new C();
|
new C();
|
||||||
|
|
||||||
|
@ -7,12 +7,11 @@ path: language/expressions/class/fields-derived-cls-indirect-
|
|||||||
name: indirect eval
|
name: indirect eval
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var A = class {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
|
var A = class {}
|
||||||
var C = class extends A {
|
var C = class extends A {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
||||||
}
|
};
|
||||||
|
|
||||||
assert.throws(SyntaxError, function() {
|
assert.throws(SyntaxError, function() {
|
||||||
new C();
|
new C();
|
||||||
|
@ -5,12 +5,12 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-derived-cls-direct-
|
path: language/statements/class/fields-derived-cls-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
class A = {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
class C extends A = {
|
class A = {}
|
||||||
|
class C extends A {
|
||||||
x = eval('executed = true; /*{ initializer }*/;';
|
x = eval('executed = true; /*{ initializer }*/;';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,12 +5,13 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-derived-cls-indirect-
|
path: language/statements/class/fields-derived-cls-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
class A = {}
|
class A = {}
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
class C extends A = {
|
class C extends A {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;';
|
x = (0, eval)('executed = true; /*{ initializer }*/;';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,14 +5,14 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-derived-cls-direct-
|
path: language/expressions/class/fields-derived-cls-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
A = class {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
C = class extends A {
|
var A = class {}
|
||||||
|
var C = class extends A {
|
||||||
x = eval('executed = true; /*{ initializer }*/;';
|
x = eval('executed = true; /*{ initializer }*/;';
|
||||||
}
|
};
|
||||||
|
|
||||||
assert.throws(/*{ earlyerror }*/, function() {
|
assert.throws(/*{ earlyerror }*/, function() {
|
||||||
new C();
|
new C();
|
||||||
|
@ -5,14 +5,14 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-derived-cls-indirect-
|
path: language/expressions/class/fields-derived-cls-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
A = class {}
|
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
C = class extends A {
|
var A = class {}
|
||||||
|
var C = class extends A {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;';
|
x = (0, eval)('executed = true; /*{ initializer }*/;';
|
||||||
}
|
};
|
||||||
|
|
||||||
assert.throws(/*{ executionerror }*/, function() {
|
assert.throws(/*{ executionerror }*/, function() {
|
||||||
new C();
|
new C();
|
||||||
|
@ -5,10 +5,11 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-direct-
|
path: language/statements/class/fields-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
class C = {
|
class C {
|
||||||
x = eval('executed = true; /*{ initializer }*/;');
|
x = eval('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,10 +5,11 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/statements/class/fields-indirect-
|
path: language/statements/class/fields-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
class C = {
|
class C {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,10 +5,11 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-direct-
|
path: language/expressions/class/fields-direct-
|
||||||
name: direct eval
|
name: direct eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
C = class {
|
var C = class {
|
||||||
x = eval('executed = true; /*{ initializer }*/;');
|
x = eval('executed = true; /*{ initializer }*/;');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,12 +5,13 @@
|
|||||||
esid: sec-performeval-rules-in-initializer
|
esid: sec-performeval-rules-in-initializer
|
||||||
path: language/expressions/class/fields-indirect-
|
path: language/expressions/class/fields-indirect-
|
||||||
name: indirect eval
|
name: indirect eval
|
||||||
|
features: [class, class-fields-public]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var executed = false;
|
var executed = false;
|
||||||
C = class {
|
var C = class {
|
||||||
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
x = (0, eval)('executed = true; /*{ initializer }*/;');
|
||||||
}
|
};
|
||||||
|
|
||||||
assert.throws(/*{ executionerror }*/, function() {
|
assert.throws(/*{ executionerror }*/, function() {
|
||||||
new C();
|
new C();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user