mirror of
https://github.com/microsoft/vscode.git
synced 2026-06-04 22:54:33 +01:00
nes: fix: dispose RejectionCollector (#744)
This commit is contained in:
committed by
GitHub
parent
724183bf9f
commit
dc3d13ad31
@@ -13,7 +13,7 @@ import { StringEdit, StringReplacement } from '../../../util/vs/editor/common/co
|
||||
import { StringText } from '../../../util/vs/editor/common/core/text/abstractText';
|
||||
|
||||
export class RejectionCollector extends Disposable {
|
||||
private readonly _garbageCollector = new LRUGarbageCollector(20);
|
||||
private readonly _garbageCollector = this._register(new LRUGarbageCollector(20));
|
||||
private readonly _documentCaches = new Map<DocumentId, DocumentRejectionTracker>();
|
||||
private readonly _tracer: ITracer;
|
||||
|
||||
|
||||
@@ -62,7 +62,7 @@ export class NextEditProvider extends Disposable implements INextEditProvider<Ne
|
||||
|
||||
public readonly ID = this._statelessNextEditProvider.ID;
|
||||
|
||||
private readonly _rejectionCollector = new RejectionCollector(this._workspace, s => this._logService.trace(s));
|
||||
private readonly _rejectionCollector = this._register(new RejectionCollector(this._workspace, s => this._logService.trace(s)));
|
||||
private readonly _nextEditCache: NextEditCache;
|
||||
private readonly _recentlyShownCache = new RecentlyShownCache();
|
||||
|
||||
|
||||
+2
-2
@@ -199,7 +199,7 @@ export class DiagnosticsCompletionProcessor extends Disposable {
|
||||
return providers;
|
||||
}).recomputeInitiallyAndOnChange(this._store);
|
||||
|
||||
this._rejectionCollector = new RejectionCollector(this._workspace, s => this._tracer.trace(s));
|
||||
this._rejectionCollector = this._register(new RejectionCollector(this._workspace, s => this._tracer.trace(s)));
|
||||
|
||||
const isValidEditor = (editor: vscode.TextEditor | undefined): editor is vscode.TextEditor => {
|
||||
return !!editor && (isNotebookCell(editor.document.uri) || isEditorFromEditorGrid(editor));
|
||||
@@ -700,4 +700,4 @@ class DiagnosticsCompletionHandlerTelemetry {
|
||||
hasAlternativeDiagnosticForSameRange: this._hasAlternativeDiagnosticForSameRange
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user