Generate tests

This commit is contained in:
Leo Balter 2018-11-05 12:03:36 -05:00 committed by Rick Waldron
parent 6a9a6f5698
commit 69c1efd325
102 changed files with 5010 additions and 0 deletions

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
*m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
*m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
*m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-async-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static async *m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-async-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static async *m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-async-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static async *m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-async-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static async m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-async-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static async m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-async-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static async m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static *m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static *m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static *m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(C.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-static-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
static m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(C.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,80 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-multiple-definitions.template
/*---
description: PrivateName CallExpression usage (private field) (multiple fields definitions)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
foo = "foobar";
m() { return 42 }
#m = 'test262';
m2() { return 39 }
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.m2(), 39);
assert.sameValue(Object.hasOwnProperty.call(c, "m2"), false);
assert.sameValue(c.m2, C.prototype.m2);
verifyProperty(C.prototype, "m2", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,80 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-multiple-definitions.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (multiple fields definitions)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
foo = "foobar";
m() { return 42 }
get #m() { return 'test262'; }
m2() { return 39 }
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.m2(), 39);
assert.sameValue(Object.hasOwnProperty.call(c, "m2"), false);
assert.sameValue(c.m2, C.prototype.m2);
verifyProperty(C.prototype, "m2", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,80 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-multiple-definitions.template
/*---
description: PrivateName CallExpression usage (private method) (multiple fields definitions)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
foo = "foobar";
m() { return 42 }
#m() { return 'test262'; }
m2() { return 39 }
bar = "barbaz";
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.m2(), 39);
assert.sameValue(Object.hasOwnProperty.call(c, "m2"), false);
assert.sameValue(c.m2, C.prototype.m2);
verifyProperty(C.prototype, "m2", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-multiple-stacked-definitions.template
/*---
description: PrivateName CallExpression usage (private field) (multiple stacked fields definitions through ASI)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m = 'test262';
foo = "foobar"
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-multiple-stacked-definitions.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (multiple stacked fields definitions through ASI)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
get #m() { return 'test262'; }
foo = "foobar"
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-multiple-stacked-definitions.template
/*---
description: PrivateName CallExpression usage (private method) (multiple stacked fields definitions through ASI)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m() { return 'test262'; }
foo = "foobar"
bar = "barbaz";
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-new-no-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in a new line without a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m = 'test262';
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-new-no-sc-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in a new line without a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
get #m() { return 'test262'; }
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-new-no-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in a new line without a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m() { return 'test262'; }
m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-new-sc-line-generator.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m = 'test262';;
*m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-new-sc-line-generator.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
get #m() { return 'test262'; };
*m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-new-sc-line-generator.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m() { return 'test262'; };
*m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-new-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m = 'test262';;
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-new-sc-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
get #m() { return 'test262'; };
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-new-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m() { return 'test262'; };
m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,33 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-regular-definitions.template
/*---
description: PrivateName CallExpression usage (private field) (regular fields defintion)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m = 'test262';
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,33 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-regular-definitions.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (regular fields defintion)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
get #m() { return 'test262'; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,33 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-regular-definitions.template
/*---
description: PrivateName CallExpression usage (private method) (regular fields defintion)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m() { return 'test262'; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-async-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after an async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
async *m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-async-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after an async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
async *m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-async-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after an async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
async *m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-async-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after an async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
async m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-async-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after an async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
async m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-after-same-line-async-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after an async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
async m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-same-line-generator.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a generator method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m = 'test262';; *m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-same-line-generator.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a generator method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
get #m() { return 'test262'; }; *m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-same-line-generator.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a generator method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m() { return 'test262'; }; *m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-same-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m = 'test262';; m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-same-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
get #m() { return 'test262'; }; m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-same-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
#m() { return 'test262'; }; m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,35 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-expr-wrapped-in-sc.template
/*---
description: PrivateName CallExpression usage (private field) (fields definition wrapped in semicolons)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
;;;;
;;;;;;#m = 'test262';;;;;;;;
;;;;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,35 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-expr-wrapped-in-sc.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (fields definition wrapped in semicolons)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
;;;;
;;;;;;get #m() { return 'test262'; };;;;;;;
;;;;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,35 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-expr-wrapped-in-sc.template
/*---
description: PrivateName CallExpression usage (private method) (fields definition wrapped in semicolons)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
var C = class {
;;;;
;;;;;;#m() { return 'test262'; };;;;;;;
;;;;
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
*m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
*m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
*m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-async-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static async *m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-async-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static async *m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-async-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static async *m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-async-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static async m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-async-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static async m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-async-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static async m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
C.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static *m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static *m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, generators, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static *m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(C.m().next().value, 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after a static method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after a static method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(C.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-static-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after a static method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
static m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(C.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "m"), false);
verifyProperty(C, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,80 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-multiple-definitions.template
/*---
description: PrivateName CallExpression usage (private field) (multiple fields definitions)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
foo = "foobar";
m() { return 42 }
#m = 'test262';
m2() { return 39 }
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.m2(), 39);
assert.sameValue(Object.hasOwnProperty.call(c, "m2"), false);
assert.sameValue(c.m2, C.prototype.m2);
verifyProperty(C.prototype, "m2", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,80 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-multiple-definitions.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (multiple fields definitions)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
foo = "foobar";
m() { return 42 }
get #m() { return 'test262'; }
m2() { return 39 }
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.m2(), 39);
assert.sameValue(Object.hasOwnProperty.call(c, "m2"), false);
assert.sameValue(c.m2, C.prototype.m2);
verifyProperty(C.prototype, "m2", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,80 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-multiple-definitions.template
/*---
description: PrivateName CallExpression usage (private method) (multiple fields definitions)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
foo = "foobar";
m() { return 42 }
#m() { return 'test262'; }
m2() { return 39 }
bar = "barbaz";
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.m2(), 39);
assert.sameValue(Object.hasOwnProperty.call(c, "m2"), false);
assert.sameValue(c.m2, C.prototype.m2);
verifyProperty(C.prototype, "m2", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-multiple-stacked-definitions.template
/*---
description: PrivateName CallExpression usage (private field) (multiple stacked fields definitions through ASI)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m = 'test262';
foo = "foobar"
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-multiple-stacked-definitions.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (multiple stacked fields definitions through ASI)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
get #m() { return 'test262'; }
foo = "foobar"
bar = "barbaz";
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-multiple-stacked-definitions.template
/*---
description: PrivateName CallExpression usage (private method) (multiple stacked fields definitions through ASI)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m() { return 'test262'; }
foo = "foobar"
bar = "barbaz";
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.foo, "foobar");
assert.sameValue(Object.hasOwnProperty.call(C, "foo"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "foo"), false);
verifyProperty(c, "foo", {
value: "foobar",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.bar, "barbaz");
assert.sameValue(Object.hasOwnProperty.call(C, "bar"), false);
assert.sameValue(Object.hasOwnProperty.call(C.prototype, "bar"), false);
verifyProperty(c, "bar", {
value: "barbaz",
enumerable: true,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-new-no-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in a new line without a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m = 'test262';
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-new-no-sc-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in a new line without a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
get #m() { return 'test262'; }
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-new-no-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in a new line without a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m() { return 'test262'; }
m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-new-sc-line-generator.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m = 'test262';;
*m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-new-sc-line-generator.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
get #m() { return 'test262'; };
*m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-new-sc-line-generator.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m() { return 'test262'; };
*m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-new-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m = 'test262';;
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-new-sc-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
get #m() { return 'test262'; };
m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,45 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-new-sc-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in a new line with a semicolon)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m() { return 'test262'; };
m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,33 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-regular-definitions.template
/*---
description: PrivateName CallExpression usage (private field) (regular fields defintion)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m = 'test262';
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,33 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-regular-definitions.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (regular fields defintion)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
get #m() { return 'test262'; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,33 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-regular-definitions.template
/*---
description: PrivateName CallExpression usage (private method) (regular fields defintion)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m() { return 'test262'; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-async-gen.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after an async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
async *m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-async-gen.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after an async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
async *m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,58 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-async-gen.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after an async generator in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-iteration]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
async *m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().next().then(function(v) {
assert.sameValue(v.value, 42);
assert.sameValue(v.done, true);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-async-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions after an async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
async m() { return 42; } #m = 'test262';;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-async-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions after an async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
async m() { return 42; } get #m() { return 'test262'; };
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,57 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-after-same-line-async-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions after an async method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, async-functions]
flags: [generated, async]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
async m() { return 42; } #m() { return 'test262'; };
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
assert.sameValue(c.m, C.prototype.m);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
}, {restore: true});
c.m().then(function(v) {
assert.sameValue(v, 42);
function assertions() {
// Cover $DONE handler for async cases.
function $DONE(error) {
if (error) {
throw new Test262Error('Test262:AsyncTestFailure')
}
}
assert.sameValue(c.method(), 'test262');
}
return Promise.resolve(assertions());
}, $DONE).then($DONE, $DONE);

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-same-line-generator.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a generator method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m = 'test262';; *m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-same-line-generator.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a generator method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
get #m() { return 'test262'; }; *m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-same-line-generator.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a generator method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public, generators]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m() { return 'test262'; }; *m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m().next().value, 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-same-line-method.template
/*---
description: PrivateName CallExpression usage (private field) (field definitions followed by a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m = 'test262';; m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-getter-usage.case
// - src/class-elements/productions/cls-decl-same-line-method.template
/*---
description: PrivateName CallExpression usage (Accesor get method) (field definitions followed by a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
get #m() { return 'test262'; }; m() { return 42; }
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,44 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-method-usage.case
// - src/class-elements/productions/cls-decl-same-line-method.template
/*---
description: PrivateName CallExpression usage (private method) (field definitions followed by a method in the same line)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
includes: [propertyHelper.js]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
#m() { return 'test262'; }; m() { return 42; }
method() {
return this.#m();
}
}
var c = new C();
assert.sameValue(c.m(), 42);
assert.sameValue(c.m, C.prototype.m);
assert.sameValue(Object.hasOwnProperty.call(c, "m"), false);
verifyProperty(C.prototype, "m", {
enumerable: false,
configurable: true,
writable: true,
});
assert.sameValue(c.method(), 'test262');

View File

@ -0,0 +1,35 @@
// This file was procedurally generated from the following sources:
// - src/class-elements/private-field-usage.case
// - src/class-elements/productions/cls-decl-wrapped-in-sc.template
/*---
description: PrivateName CallExpression usage (private field) (fields definition wrapped in semicolons)
esid: prod-FieldDefinition
features: [class-methods-private, class, class-fields-public]
flags: [generated]
info: |
Updated Productions
CallExpression[Yield, Await]:
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await]
SuperCall[?Yield, ?Await]
CallExpression[?Yield, ?Await]Arguments[?Yield, ?Await]
CallExpression[?Yield, ?Await][Expression[+In, ?Yield, ?Await]]
CallExpression[?Yield, ?Await].IdentifierName
CallExpression[?Yield, ?Await]TemplateLiteral[?Yield, ?Await]
CallExpression[?Yield, ?Await].PrivateName
---*/
class C {
;;;;
;;;;;;#m = 'test262';;;;;;;;
;;;;
method() {
return this.#m;
}
}
var c = new C();
assert.sameValue(c.method(), 'test262');

Some files were not shown because too many files have changed in this diff Show More