diff --git a/src/compiler/tsc.ts b/src/compiler/tsc.ts index a0d21106f43..0cbeff8204a 100644 --- a/src/compiler/tsc.ts +++ b/src/compiler/tsc.ts @@ -276,6 +276,7 @@ module ts { // If a source file changes, mark it as unwatched and start the recompilation timer function sourceFileChanged(sourceFile: SourceFile) { + sourceFile.fileWatcher.close(); sourceFile.fileWatcher = undefined; startTimer(); }