mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-04 07:00:35 +02:00
codetools: h2p: fixed updating neighborhood when removing IFDEF
git-svn-id: trunk@14670 -
This commit is contained in:
parent
3c07a0a998
commit
61d830f202
@ -1681,16 +1681,18 @@ begin
|
||||
h2pdnElseIf:
|
||||
begin
|
||||
Sibling.Expression:='('+Sibling.Expression+') and '+Expression;
|
||||
if TH2PDirectiveNode(Sibling.PriorBrother).Desc<>h2pdnElseIf then
|
||||
if (Sibling.PriorBrother=Node) and (Node.Desc<>h2pdnElseIf) then
|
||||
Sibling.Desc:=h2pdnIf;
|
||||
DebugLn(['TH2PasTool.DeleteDirectiveNode ADAPTED neighbour: ',Sibling.DescAsString(CTool)]);
|
||||
end;
|
||||
h2pdnElse:
|
||||
begin
|
||||
Sibling.Expression:=Expression;
|
||||
if TH2PDirectiveNode(Sibling.PriorBrother).Desc<>h2pdnElseIf then
|
||||
if (Sibling.PriorBrother=Node) and (Node.Desc<>h2pdnElseIf) then
|
||||
Sibling.Desc:=h2pdnIf
|
||||
else
|
||||
Sibling.Desc:=h2pdnElseIf;
|
||||
DebugLn(['TH2PasTool.DeleteDirectiveNode ADAPTED neighbour: ',Sibling.DescAsString(CTool)]);
|
||||
end;
|
||||
else break;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user