mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-16 11:59:27 +02:00
* make ResetProcessing more efficient
git-svn-id: trunk@26163 -
This commit is contained in:
parent
e914612423
commit
35206c3d93
@ -137,6 +137,14 @@ unit optdfa;
|
|||||||
function ResetProcessing(var n: tnode; arg: pointer): foreachnoderesult;
|
function ResetProcessing(var n: tnode; arg: pointer): foreachnoderesult;
|
||||||
begin
|
begin
|
||||||
exclude(n.flags,nf_processing);
|
exclude(n.flags,nf_processing);
|
||||||
|
{ dfa works only on normalized trees, so do not recurse into expressions, because
|
||||||
|
ResetProcessing eats a signififcant amount of time of CheckAndWarn
|
||||||
|
|
||||||
|
the following set contains (hopefully) most of the expression nodes }
|
||||||
|
if n.nodetype in [calln,inlinen,assignn,callparan,andn,addn,orn,subn,muln,divn,slashn,notn,equaln,unequaln,gtn,ltn,lten,gten,loadn,
|
||||||
|
typeconvn,vecn,subscriptn,addrn,derefn] then
|
||||||
|
result:=fen_norecurse_false
|
||||||
|
else
|
||||||
result:=fen_false;
|
result:=fen_false;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user