mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 07:26:24 +02:00
* Inc/Dec nodes converted to Add/Sub now remove
the "nf_modify" flag from the destination so constant propagation works more efficiently.
This commit is contained in:
parent
e7145f5f7c
commit
e60a7d01a4
@ -4947,6 +4947,8 @@ implementation
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
resultnode := hp.getcopy;
|
resultnode := hp.getcopy;
|
||||||
|
{ Remove "modify" flag from what will be an assignment destination }
|
||||||
|
Exclude(resultnode.flags, nf_modify);
|
||||||
|
|
||||||
{ avoid type errors from the addn/subn }
|
{ avoid type errors from the addn/subn }
|
||||||
if not is_integer(resultnode.resultdef) then
|
if not is_integer(resultnode.resultdef) then
|
||||||
@ -4955,7 +4957,7 @@ implementation
|
|||||||
inserttypeconv_internal(hpp,sinttype);
|
inserttypeconv_internal(hpp,sinttype);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ addition/substraction depending on inc/dec }
|
{ addition/subtraction depending on inc/dec }
|
||||||
if inlinenumber = in_inc_x then
|
if inlinenumber = in_inc_x then
|
||||||
hpp := caddnode.create_internal(addn,hp,hpp)
|
hpp := caddnode.create_internal(addn,hp,hpp)
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user