* remove type case when loading constant in tattreader.BuildConstantOperand, resolves #33202, should not hurt other targets

git-svn-id: trunk@38307 -
This commit is contained in:
florian 2018-02-21 20:24:10 +00:00
parent 18c2f72314
commit d16a22e42b
3 changed files with 12 additions and 1 deletions

1
.gitattributes vendored
View File

@ -16011,6 +16011,7 @@ tests/webtbs/tw33086.pp svneol=native#text/pascal
tests/webtbs/tw3309.pp svneol=native#text/plain
tests/webtbs/tw33098.pp svneol=native#text/pascal
tests/webtbs/tw3320.pp svneol=native#text/plain
tests/webtbs/tw33202.pp svneol=native#text/pascal
tests/webtbs/tw3324.pp svneol=native#text/plain
tests/webtbs/tw3327.pp svneol=native#text/plain
tests/webtbs/tw3328.pp svneol=native#text/plain

View File

@ -1723,7 +1723,7 @@ unit raatt;
else
begin
oper.opr.typ:=OPR_CONSTANT;
oper.opr.val:=aint(l);
oper.opr.val:=l;
end;
end;

10
tests/webtbs/tw33202.pp Normal file
View File

@ -0,0 +1,10 @@
{ %CPU=avr }
{ %OPT=-Sm }
program macrotest;
const
sramMax = FPC_SRAMBASE + FPC_SRAMSIZE - 1;
begin
asm
sts sramMax , r31 // macrotest.pp(13,16) Error: Constant value out of bounds
end;
end.