mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-15 21:49:06 +02:00
* fixed disposing of tree node
This commit is contained in:
parent
8b82809292
commit
4fbc3dbb9e
@ -149,7 +149,7 @@ unit tree;
|
|||||||
|
|
||||||
{ allows to determine which elementes are to be replaced }
|
{ allows to determine which elementes are to be replaced }
|
||||||
tdisposetyp = (dt_nothing,dt_leftright,dt_left,dt_leftrighthigh,
|
tdisposetyp = (dt_nothing,dt_leftright,dt_left,dt_leftrighthigh,
|
||||||
dt_mbleft,dt_typeconv,dt_inlinen,
|
dt_mbleft,dt_typeconv,dt_inlinen,dt_leftrightmethod,
|
||||||
dt_mbleft_and_method,dt_loop,dt_case,dt_with,dt_onn);
|
dt_mbleft_and_method,dt_loop,dt_case,dt_with,dt_onn);
|
||||||
|
|
||||||
{ different assignment types }
|
{ different assignment types }
|
||||||
@ -390,6 +390,15 @@ unit tree;
|
|||||||
if assigned(p^.hightree) then
|
if assigned(p^.hightree) then
|
||||||
hp^.left:=getcopy(p^.hightree);
|
hp^.left:=getcopy(p^.hightree);
|
||||||
end;
|
end;
|
||||||
|
dt_leftrightmethod :
|
||||||
|
begin
|
||||||
|
if assigned(p^.left) then
|
||||||
|
hp^.left:=getcopy(p^.left);
|
||||||
|
if assigned(p^.right) then
|
||||||
|
hp^.right:=getcopy(p^.right);
|
||||||
|
if assigned(p^.methodpointer) then
|
||||||
|
hp^.left:=getcopy(p^.methodpointer);
|
||||||
|
end;
|
||||||
dt_nothing : ;
|
dt_nothing : ;
|
||||||
dt_left :
|
dt_left :
|
||||||
if assigned(p^.left) then
|
if assigned(p^.left) then
|
||||||
@ -487,6 +496,15 @@ unit tree;
|
|||||||
if assigned(p^.hightree) then
|
if assigned(p^.hightree) then
|
||||||
disposetree(p^.hightree);
|
disposetree(p^.hightree);
|
||||||
end;
|
end;
|
||||||
|
dt_leftrightmethod :
|
||||||
|
begin
|
||||||
|
if assigned(p^.left) then
|
||||||
|
disposetree(p^.left);
|
||||||
|
if assigned(p^.right) then
|
||||||
|
disposetree(p^.right);
|
||||||
|
if assigned(p^.methodpointer) then
|
||||||
|
disposetree(p^.methodpointer);
|
||||||
|
end;
|
||||||
dt_case :
|
dt_case :
|
||||||
begin
|
begin
|
||||||
if assigned(p^.left) then
|
if assigned(p^.left) then
|
||||||
@ -1067,7 +1085,7 @@ unit tree;
|
|||||||
p^.unit_specific:=false;
|
p^.unit_specific:=false;
|
||||||
p^.no_check:=false;
|
p^.no_check:=false;
|
||||||
p^.return_value_used:=true;
|
p^.return_value_used:=true;
|
||||||
p^.disposetyp := dt_leftright;
|
p^.disposetyp := dt_leftrightmethod;
|
||||||
p^.methodpointer:=nil;
|
p^.methodpointer:=nil;
|
||||||
p^.left:=nil;
|
p^.left:=nil;
|
||||||
p^.right:=nil;
|
p^.right:=nil;
|
||||||
@ -1093,7 +1111,7 @@ unit tree;
|
|||||||
p^.return_value_used:=true;
|
p^.return_value_used:=true;
|
||||||
p^.symtableprocentry:=v;
|
p^.symtableprocentry:=v;
|
||||||
p^.symtableproc:=st;
|
p^.symtableproc:=st;
|
||||||
p^.disposetyp:=dt_mbleft_and_method;
|
p^.disposetyp:=dt_leftrightmethod;
|
||||||
p^.left:=nil;
|
p^.left:=nil;
|
||||||
p^.right:=nil;
|
p^.right:=nil;
|
||||||
p^.methodpointer:=mp;
|
p^.methodpointer:=mp;
|
||||||
@ -1721,7 +1739,10 @@ unit tree;
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.86 1999-08-04 00:23:49 florian
|
Revision 1.87 1999-08-09 22:14:46 peter
|
||||||
|
* fixed disposing of tree node
|
||||||
|
|
||||||
|
Revision 1.86 1999/08/04 00:23:49 florian
|
||||||
* renamed i386asm and i386base to cpuasm and cpubase
|
* renamed i386asm and i386base to cpuasm and cpubase
|
||||||
|
|
||||||
Revision 1.85 1999/08/03 22:03:40 peter
|
Revision 1.85 1999/08/03 22:03:40 peter
|
||||||
|
Loading…
Reference in New Issue
Block a user