* intel assembler reader: scale factor in references can also be a constant symbol, resolves #31165

git-svn-id: trunk@35473 -
This commit is contained in:
florian 2017-02-22 20:59:52 +00:00
parent 2d36af85bb
commit b9dba41ad0
3 changed files with 24 additions and 0 deletions

1
.gitattributes vendored
View File

@ -15373,6 +15373,7 @@ tests/webtbs/tw3109.pp svneol=native#text/plain
tests/webtbs/tw3111.pp svneol=native#text/plain
tests/webtbs/tw31120.pp svneol=native#text/pascal
tests/webtbs/tw3113.pp svneol=native#text/plain
tests/webtbs/tw31165.pp svneol=native#text/pascal
tests/webtbs/tw31201.pp svneol=native#text/pascal
tests/webtbs/tw3124.pp svneol=native#text/plain
tests/webtbs/tw31246.pp svneol=native#text/pascal

View File

@ -1406,6 +1406,7 @@ Unit Rax86int;
hs:='';
l:=0;
case actasmtoken of
AS_ID,
AS_LPAREN :
l:=BuildConstExpression;
AS_INTNUM:

22
tests/webtbs/tw31165.pp Normal file
View File

@ -0,0 +1,22 @@
{ %CPU=i386 }
{$asmmode intel}
const climbsize = 4;
procedure test;
var
value : dword;
begin
asm
XOR EAX,EAX
MOV EDI,1;
LEA EAX,[EAX + EDI*climbsize]
MOV value,EAX
end;
if value<>4 then
halt(1);
end;
begin
test;
writeln('ok');
end.