* bugfix of leal problem

* bugfix of using overrides with record offsets
  * bugfix if using records to load values
This commit is contained in:
carl 1998-08-27 00:42:17 +00:00
parent 547dca7111
commit 5ce923955d

View File

@ -942,6 +942,8 @@ var
Message(assem_e_16bit_base_in_32bit_segment); Message(assem_e_16bit_base_in_32bit_segment);
exit; exit;
end; { endif } end; { endif }
{ In this case the size of the reference is not taken into account! }
instr.operands[2].size := S_NO;
end; end;
With instr do With instr do
@ -2164,11 +2166,14 @@ var
Repeat Repeat
case actasmtoken of case actasmtoken of
AS_ID: Begin AS_ID: Begin
{ we must reset the operand size - since only the last field }
{ will give us the size of the operand. }
{ instr.opsize := S_NO;}
InitAsmRef(instr); InitAsmRef(instr);
{ // var_name.typefield.typefield // } { // var_name.typefield.typefield // }
if (varname <> '') then if (varname <> '') then
Begin Begin
if not GetVarOffset(varname,actasmpattern,offset) then if not GetVarOffset(instr,varname,actasmpattern,offset,operandnum) then
Begin Begin
Message1(assem_e_unknown_id,actasmpattern); Message1(assem_e_unknown_id,actasmpattern);
end end
@ -2201,7 +2206,7 @@ var
{ [ref].typefield.typefield ... } { [ref].typefield.typefield ... }
{ basetpyename is already set up... now look for fields. } { basetpyename is already set up... now look for fields. }
Begin Begin
if not GetTypeOffset(basetypename,actasmpattern,Offset) then if not GetTypeOffset(instr,basetypename,actasmpattern,Offset,operandnum) then
Begin Begin
Message1(assem_e_unknown_id,actasmpattern); Message1(assem_e_unknown_id,actasmpattern);
end end
@ -3165,6 +3170,9 @@ var
Case actasmtoken of Case actasmtoken of
{ // Reference // } { // Reference // }
AS_PTR: Begin AS_PTR: Begin
{ tell that the instruction was overriden }
{ so we will NEVER override the opsize }
instr.operands[operandnum].overriden := TRUE;
initAsmRef(instr); initAsmRef(instr);
Consume(AS_PTR); Consume(AS_PTR);
BuildOperand(instr); BuildOperand(instr);
@ -3368,7 +3376,12 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.5 1998-08-21 08:45:53 pierre Revision 1.6 1998-08-27 00:42:17 carl
* bugfix of leal problem
* bugfix of using overrides with record offsets
* bugfix if using records to load values
Revision 1.5 1998/08/21 08:45:53 pierre
* better line info for asm statements * better line info for asm statements
Revision 1.4 1998/07/14 14:47:00 peter Revision 1.4 1998/07/14 14:47:00 peter