public void Dispose() { foreach (var doc in Documents) { doc.Dispose(); } decompileCodeState?.CancelAndDispose(); compileCodeState?.CancelAndDispose(); languageCompiler.Dispose(); }
public void Dispose() { foreach (var doc in Documents) { doc.Dispose(); } decompileCodeState?.CancelAndDispose(); compileCodeState?.CancelAndDispose(); languageCompiler.Dispose(); // Needed unless we want the memory usage to be 1GB+ after some number of edits. // The GC doesn't kick in until it's too late. GC.Collect(); GC.WaitForPendingFinalizers(); }
public void Dispose() { decompileCodeState?.CancelAndDispose(); compileCodeState?.CancelAndDispose(); languageCompiler.Dispose(); }