* handle LOC_SUBSETREG,LOC_CSUBSETREG,LOC_SUBSETREF,LOC_CSUBSETREF in

unaryminus code (a.o., fixes compiler crash with test/terecs6 on
    darwin/ppc32 under certain circumstances:
    http://www.freepascal.org/testsuite/cgi-bin/testsuite.cgi?action=3&run1id=74027&run2id=74101&testfileid=3838 )

git-svn-id: trunk@16650 -
This commit is contained in:
Jonas Maebe 2010-12-28 23:52:25 +00:00
parent a8da9e4bd1
commit 5175a5ee07
2 changed files with 4 additions and 0 deletions

View File

@ -576,6 +576,8 @@ end;
end end
else else
begin begin
if left.location.loc in [LOC_SUBSETREG,LOC_CSUBSETREG,LOC_SUBSETREF,LOC_CSUBSETREF] then
location_force_reg(current_asmdata.CurrAsmList,left.location,left.location.size,true);
location_copy(location,left.location); location_copy(location,left.location);
location.loc:=LOC_REGISTER; location.loc:=LOC_REGISTER;
case left.location.loc of case left.location.loc of

View File

@ -316,6 +316,8 @@ var
begin begin
secondpass(left); secondpass(left);
begin begin
if left.location.loc in [LOC_SUBSETREG,LOC_CSUBSETREG,LOC_SUBSETREF,LOC_CSUBSETREF] then
location_force_reg(current_asmdata.CurrAsmList,left.location,left.location.size,true);
location_copy(location, left.location); location_copy(location, left.location);
location.loc := LOC_REGISTER; location.loc := LOC_REGISTER;
case left.location.loc of case left.location.loc of