From dd5069162a042731411b48a20f7397d0bbcda2b8 Mon Sep 17 00:00:00 2001 From: Joe Savona Date: Wed, 26 Apr 2023 11:27:38 -0700 Subject: [PATCH] This page left intentionally blank Supports EmptyStatement nodes by ignoring them. Note no tests because format-on-save clears away any empty statements and there is, rather frustratingly, no way to tell VSCode not to format on save for a specific file via the file contents itself or project configuration (at least, not that i can find). --- compiler/forget/src/HIR/BuildHIR.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/compiler/forget/src/HIR/BuildHIR.ts b/compiler/forget/src/HIR/BuildHIR.ts index 188e92b5b1..eab63c1042 100644 --- a/compiler/forget/src/HIR/BuildHIR.ts +++ b/compiler/forget/src/HIR/BuildHIR.ts @@ -880,6 +880,9 @@ function lowerStatement( }); return; } + case "EmptyStatement": { + return; + } case "ForInStatement": case "ClassDeclaration": case "DeclareClass": @@ -892,7 +895,6 @@ function lowerStatement( case "DeclareOpaqueType": case "DeclareTypeAlias": case "DeclareVariable": - case "EmptyStatement": case "EnumDeclaration": case "ExportAllDeclaration": case "ExportDefaultDeclaration":