mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-19 23:49:36 +02:00
codetools: clean up
git-svn-id: trunk@26423 -
This commit is contained in:
parent
75f8643d7d
commit
e03811d82e
@ -32,8 +32,6 @@ interface
|
||||
|
||||
{$I codetools.inc}
|
||||
|
||||
{ $DEFINE DisableIgnoreErrorAfter}
|
||||
|
||||
uses
|
||||
{$IFDEF MEM_CHECK}
|
||||
MemCheck,
|
||||
|
@ -72,9 +72,6 @@ interface
|
||||
{$IFDEF ShowTriedIdentifiers}{$DEFINE DebugPrefix}{$ENDIF}
|
||||
{$IFDEF ShowTriedContexts}{$DEFINE DebugPrefix}{$ENDIF}
|
||||
|
||||
// new features
|
||||
{ $DEFINE DisableIgnoreErrorAfter}
|
||||
|
||||
uses
|
||||
{$IFDEF MEM_CHECK}
|
||||
MemCheck,
|
||||
@ -1217,7 +1214,7 @@ begin
|
||||
{$ENDIF}
|
||||
if DirtySrc<>nil then DirtySrc.Clear;
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos{$ENDIF}]);
|
||||
[btSetIgnoreErrorPos]);
|
||||
{$IFDEF CTDEBUG}
|
||||
DebugLn('TFindDeclarationTool.FindDeclarationOfIdentifier B CleanCursorPos=',dbgs(CleanCursorPos));
|
||||
{$ENDIF}
|
||||
@ -1407,8 +1404,7 @@ begin
|
||||
{$ENDIF}
|
||||
if DirtySrc<>nil then DirtySrc.Clear;
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos,{$ENDIF}
|
||||
btLoadDirtySource,btCursorPosOutAllowed]);
|
||||
[btSetIgnoreErrorPos,btLoadDirtySource,btCursorPosOutAllowed]);
|
||||
{$IFDEF CTDEBUG}
|
||||
DebugLn('TFindDeclarationTool.FindDeclaration C CleanCursorPos=',dbgs(CleanCursorPos));
|
||||
{$ENDIF}
|
||||
@ -3872,7 +3868,7 @@ begin
|
||||
ActivateGlobalWriteLock;
|
||||
try
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos{$ENDIF}]);
|
||||
[btSetIgnoreErrorPos]);
|
||||
|
||||
// find class node
|
||||
ANode:=FindDeepestNodeAtPos(CleanCursorPos,true);
|
||||
|
@ -43,10 +43,6 @@ interface
|
||||
{ $DEFINE ShowFilteredIdents}
|
||||
{ $DEFINE ShowHistory}
|
||||
|
||||
// new features
|
||||
{ $DEFINE DisableIgnoreErrorAfter}
|
||||
|
||||
|
||||
uses
|
||||
{$IFDEF MEM_CHECK}
|
||||
MemCheck,
|
||||
@ -1706,8 +1702,7 @@ begin
|
||||
{$IFDEF CTDEBUG}
|
||||
DebugLn('TIdentCompletionTool.ParseSourceTillCollectionStart A CursorPos=',dbgs(CursorPos.X),',',dbgs(CursorPos.Y),' ',DbgsCXY(IdentStartXYPos));
|
||||
{$ENDIF}
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos{$ENDIF}]);
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,[btSetIgnoreErrorPos]);
|
||||
|
||||
// find node at position
|
||||
CursorNode:=BuildSubTreeAndFindDeepestNodeAtPos(CleanCursorPos,true);
|
||||
@ -2388,7 +2383,7 @@ begin
|
||||
Params:=nil;
|
||||
try
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos{$ENDIF}]);
|
||||
[btSetIgnoreErrorPos]);
|
||||
|
||||
// find node at position
|
||||
CursorNode:=BuildSubTreeAndFindDeepestNodeAtPos(CleanCursorPos,true);
|
||||
@ -2462,7 +2457,7 @@ begin
|
||||
Params:=nil;
|
||||
try
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos{$ENDIF}]);
|
||||
[btSetIgnoreErrorPos]);
|
||||
|
||||
// find node at position
|
||||
CursorNode:=BuildSubTreeAndFindDeepestNodeAtPos(CleanCursorPos,true);
|
||||
|
@ -41,7 +41,6 @@ interface
|
||||
|
||||
{$I codetools.inc}
|
||||
|
||||
{ $DEFINE DisableIgnoreErrorAfter}
|
||||
{$DEFINE VerboseGetStringConstBounds}
|
||||
{ $DEFINE ShowCompleteBlock}
|
||||
|
||||
@ -6049,7 +6048,7 @@ begin
|
||||
Result:=false;
|
||||
NewPos:=CursorPos;
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos{$ENDIF}]);
|
||||
[btSetIgnoreErrorPos]);
|
||||
StartNode:=FindDeepestNodeAtPos(CleanCursorPos,true);
|
||||
|
||||
SourceChangeCache.MainScanner:=Scanner;
|
||||
@ -6120,7 +6119,7 @@ begin
|
||||
Result:=false;
|
||||
try
|
||||
BuildTreeAndGetCleanPos(trTillCursor,CursorPos,CleanCursorPos,
|
||||
[{$IFNDEF DisableIgnoreErrorAfter}btSetIgnoreErrorPos{$ENDIF}]);
|
||||
[btSetIgnoreErrorPos]);
|
||||
LinkIndex:=Scanner.LinkIndexAtCleanPos(CleanCursorPos);
|
||||
LinkIndex:=Scanner.FindParentLink(LinkIndex);
|
||||
if LinkIndex<0 then
|
||||
|
Loading…
Reference in New Issue
Block a user