mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-01 21:20:28 +02:00
codetools: safety clean up on exception
git-svn-id: trunk@40681 -
This commit is contained in:
parent
63634bb913
commit
480fedbcc8
@ -1667,12 +1667,14 @@ begin
|
||||
ClearCurCodeTool;
|
||||
MainCode:=GetMainCode(Code);
|
||||
if MainCode=nil then begin
|
||||
FErrorLine:=1;
|
||||
FErrorColumn:=1;
|
||||
fErrorCode:=Code;
|
||||
if Code = nil then
|
||||
begin
|
||||
fErrorMsg:='TCodeToolManager.InitCurCodeTool Code=nil'
|
||||
end
|
||||
else begin
|
||||
fErrorCode:=Code;
|
||||
FErrorLine:=1;
|
||||
FErrorColumn:=1;
|
||||
fErrorMsg:='unit of include file is not known (hint: open and explore unit first)';
|
||||
end;
|
||||
exit;
|
||||
|
Loading…
Reference in New Issue
Block a user