Files
tsgo/testdata/baselines/reference/submodule/conformance/classStaticBlock26(target=esnext).js

68 lines
1.5 KiB
TypeScript

//// [tests/cases/conformance/classes/classStaticBlock/classStaticBlock26.ts] ////
//// [classStaticBlock26.ts]
class C {
static {
await; // illegal
}
static {
await (1); // illegal
}
static {
({ [await]: 1 }); // illegal
}
static {
class D {
[await] = 1; // illegal (computed property names are evaluated outside of a class body
};
}
static {
({ await }); // illegal short-hand property reference
}
static {
await: // illegal, 'await' cannot be used as a label
break await; // illegal, 'await' cannot be used as a label
}
static {
function f(await) { }
const ff = (await) => { }
const fff = await => { }
}
}
//// [classStaticBlock26.js]
"use strict";
class C {
static {
await ; // illegal
}
static {
await (1); // illegal
}
static {
({ [await ]: 1 }); // illegal
}
static {
class D {
[await ] = 1; // illegal (computed property names are evaluated outside of a class body
}
;
}
static {
({ await: }); // illegal short-hand property reference
}
static {
await ;
break ;
await ; // illegal, 'await' cannot be used as a label
}
static {
function f(await) { }
const ff = (await );
{ }
const fff = await ;
{ }
}
}