pexpr.pas, post_comp_expr_gendef:

This is not the result you are looking for: The result of "postfixoperators" is only set to true if either "again" was "true" once or the node was changed to an errornode. So using the result for deciding whether we overwrite the def or not is incorrect. So just call "postfixoperators" and process the returned node accordingly.

git-svn-id: branches/svenbarth/generics@19731 -
This commit is contained in:
svenbarth 2011-12-03 10:53:02 +00:00
parent 06ebfcd360
commit aca2bd83c7

View File

@ -2975,11 +2975,11 @@ implementation
{ handle potential typecasts, etc } { handle potential typecasts, etc }
p1:=handle_factor_typenode(def,false,again,nil,false); p1:=handle_factor_typenode(def,false,again,nil,false);
{ parse postfix operators } { parse postfix operators }
if postfixoperators(p1,again,false) then postfixoperators(p1,again,false);
if assigned(p1) and (p1.nodetype=typen) then if assigned(p1) and (p1.nodetype=typen) then
def:=ttypenode(p1).typedef def:=ttypenode(p1).typedef
else else
def:=generrordef; def:=generrordef;
end; end;
{**************************************************************************** {****************************************************************************