diff --git a/CodeCompletion/DomConverter.cs b/CodeCompletion/DomConverter.cs index 601ecf7eb..ae6871e64 100644 --- a/CodeCompletion/DomConverter.cs +++ b/CodeCompletion/DomConverter.cs @@ -1127,6 +1127,11 @@ namespace CodeCompletion if (tmp_cur_used_assemblies != null) PascalABCCompiler.NetHelper.NetHelper.cur_used_assemblies = tmp_cur_used_assemblies; } + + ~DomConverter() + { + + } } } diff --git a/CodeCompletion/DomSyntaxTreeVisitor.cs b/CodeCompletion/DomSyntaxTreeVisitor.cs index 8472b5891..2b65ea052 100644 --- a/CodeCompletion/DomSyntaxTreeVisitor.cs +++ b/CodeCompletion/DomSyntaxTreeVisitor.cs @@ -63,7 +63,7 @@ namespace CodeCompletion #if DEBUG File.AppendAllText("log.txt", e.Message + Environment.NewLine + e.StackTrace + Environment.NewLine); #endif - throw e; + //throw e; //System.Diagnostics.Debug.WriteLine(e.StackTrace); } } @@ -1971,9 +1971,7 @@ namespace CodeCompletion if (add_doc_from_text && this.converter.controller.docs != null && this.converter.controller.docs.ContainsKey(_unit_module.unit_name)) cur_scope.AddDocumentation(this.converter.controller.docs[_unit_module.unit_name]); entry_scope = cur_scope; - //add_standart_types(); if (_unit_module.unit_name.idunit_name.name == this.converter.controller.Parser.LanguageInformation.SystemUnitName) - //add_system_unit(); { is_system_unit = true; add_standart_types(entry_scope); @@ -1993,8 +1991,6 @@ namespace CodeCompletion ns_cache[s] = s; } } - //if (parse_only_interface) - // return; if (_unit_module.implementation_part != null) _unit_module.implementation_part.visit(this); if (_unit_module.initialization_part != null) @@ -2003,11 +1999,6 @@ namespace CodeCompletion SymScope stmt_scope = new BlockScope(cur_scope); cur_scope.AddName("$block_scope",stmt_scope); stmt_scope.loc = get_location(_unit_module.initialization_part); - /*if (_unit_module.implementation_part != null) - { - cur_scope.loc.end_line_num = entry_scope.loc.end_line_num; - cur_scope.loc.end_column_num = entry_scope.loc.end_column_num; - }*/ cur_scope = stmt_scope; _unit_module.initialization_part.visit(this); cur_scope = tmp; @@ -2018,11 +2009,6 @@ namespace CodeCompletion SymScope stmt_scope = new BlockScope(cur_scope); cur_scope.AddName("$block_scope",stmt_scope); stmt_scope.loc = get_location(_unit_module.finalization_part); - /*if (_unit_module.implementation_part != null) - { - cur_scope.loc.end_line_num = entry_scope.loc.end_line_num; - cur_scope.loc.end_column_num =entry_scope.loc.end_column_num; - }*/ cur_scope = stmt_scope; _unit_module.finalization_part.visit(this); cur_scope = tmp; diff --git a/CodeCompletion/SymTable.cs b/CodeCompletion/SymTable.cs index 6937e8962..fe0043eba 100644 --- a/CodeCompletion/SymTable.cs +++ b/CodeCompletion/SymTable.cs @@ -201,7 +201,9 @@ namespace CodeCompletion foreach (ProcScope meth in meths) ts.RemoveExtensionMethod(ts, meth); } + extension_methods.Clear(); } + UnitDocCache.RemoveItem(this); declaringUnit = null; topScope = null; } @@ -1020,6 +1022,11 @@ namespace CodeCompletion si.description = this.ToString(); } + ~InterfaceUnitScope() + { + + } + IImplementationUnitScope IInterfaceUnitScope.ImplementationUnitScope { get diff --git a/CodeCompletion/UnitXmlDocs.cs b/CodeCompletion/UnitXmlDocs.cs index 91754d346..5cd14d163 100644 --- a/CodeCompletion/UnitXmlDocs.cs +++ b/CodeCompletion/UnitXmlDocs.cs @@ -360,6 +360,11 @@ namespace CodeCompletion { elem_cache.Add(value); } + + public static void RemoveItem(SymScope item) + { + elem_cache.Remove(item); + } } } diff --git a/TestSuite/CompilationSamples/SyntaxTree.pas b/TestSuite/CompilationSamples/SyntaxTree.pas index e43ee0880..13a78852b 100644 --- a/TestSuite/CompilationSamples/SyntaxTree.pas +++ b/TestSuite/CompilationSamples/SyntaxTree.pas @@ -1,4 +1,4 @@ -unit SyntaxTree; +unit SyntaxTree; interface diff --git a/VisualPascalABCNET/IB/CodeCompletion/CodeCompletionParserController.cs b/VisualPascalABCNET/IB/CodeCompletion/CodeCompletionParserController.cs index 62c02c209..a0cecba36 100644 --- a/VisualPascalABCNET/IB/CodeCompletion/CodeCompletionParserController.cs +++ b/VisualPascalABCNET/IB/CodeCompletion/CodeCompletionParserController.cs @@ -244,7 +244,7 @@ namespace VisualPascalABC } } } - if (is_comp && Environment.WorkingSet > 60000000 /*&& mem_delta > 10000000*/) + if (is_comp && mem_delta > 20000000 /*&& mem_delta > 10000000*/) //postavil delta dlja pamjati, posle kototoj delaetsja sborka musora { mem_delta = 0;