Try interuprting getErr requests for user actions

Fixes #57542
This commit is contained in:
Matt Bierner
2018-09-05 10:11:08 -07:00
parent 420917046b
commit a9e93b1055

View File

@@ -274,17 +274,15 @@ export default class BufferSyncSupport extends Disposable {
}
public interuptGetErr<R>(f: () => R): R {
// TODO: re-enable for 1.27 insiders
return f();
// if (!this.pendingGetErr) {
// return f();
// }
if (!this.pendingGetErr) {
return f();
}
// this.pendingGetErr.cancel();
// this.pendingGetErr = undefined;
// const result = f();
// this.triggerDiagnostics();
// return result;
this.pendingGetErr.cancel();
this.pendingGetErr = undefined;
const result = f();
this.triggerDiagnostics();
return result;
}
private onDidCloseTextDocument(document: vscode.TextDocument): void {