mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-14 22:59:29 +02:00
* make ResetProcessing more efficient
git-svn-id: trunk@26163 -
This commit is contained in:
parent
e914612423
commit
35206c3d93
@ -137,7 +137,15 @@ unit optdfa;
|
||||
function ResetProcessing(var n: tnode; arg: pointer): foreachnoderesult;
|
||||
begin
|
||||
exclude(n.flags,nf_processing);
|
||||
result:=fen_false;
|
||||
{ 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;
|
||||
end;
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user