diff --git a/src/compiler.ts b/src/compiler.ts index e035cab8ca..de143a6f25 100644 --- a/src/compiler.ts +++ b/src/compiler.ts @@ -3514,6 +3514,16 @@ export class Compiler extends DiagnosticEmitter { this.currentType = compiled.type; break; } + case NodeKind.CLASS: { + // TODO: compile as class expression + this.error( + DiagnosticCode.Not_implemented_0, + expression.range, + "Block-scoped class declarations or expressions" + ); + expr = this.module.unreachable(); + break; + } default: { assert(false); expr = this.module.unreachable();