Skip to content

Commit 8bae521

Browse files
committed
Fix noEmit handling for tsbuildinfo emit with SemanticDiagnosticBuilder
1 parent 6a05abd commit 8bae521

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/compiler/builder.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -1069,7 +1069,8 @@ namespace ts {
10691069
}
10701070

10711071
// Add file to affected file pending emit to handle for later emit time
1072-
if (kind === BuilderProgramKind.EmitAndSemanticDiagnosticsBuilderProgram) {
1072+
// Apart for emit builder do this for tsbuildinfo, do this for non emit builder when noEmit is set as tsbuildinfo is written and reused between emitters
1073+
if (kind === BuilderProgramKind.EmitAndSemanticDiagnosticsBuilderProgram || state.compilerOptions.noEmit) {
10731074
addToAffectedFilesPendingEmit(state, (affected as SourceFile).resolvedPath, BuilderFileEmit.Full);
10741075
}
10751076

0 commit comments

Comments
 (0)