mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-11-27 14:57:15 +01:00
* fix for uggly bug of Marco
This commit is contained in:
parent
4847611b50
commit
ff8ba9c049
@ -1589,14 +1589,32 @@ procedure mov_reg_to_dest(p : ptree; s : topsize; reg : tregister);
|
|||||||
((p^.resulttype^.deftype=objectdef) and
|
((p^.resulttype^.deftype=objectdef) and
|
||||||
pobjectdef(p^.resulttype)^.is_class) then
|
pobjectdef(p^.resulttype)^.is_class) then
|
||||||
begin
|
begin
|
||||||
inc(pushedparasize,4);
|
if (p^.resulttype^.size>2) or
|
||||||
if inlined then
|
(alignment=4) then
|
||||||
begin
|
begin
|
||||||
r:=new_reference(procinfo^.framepointer,para_offset-pushedparasize);
|
inc(pushedparasize,4);
|
||||||
concatcopy(tempreference,r^,4,false,false);
|
if inlined then
|
||||||
|
begin
|
||||||
|
r:=new_reference(procinfo^.framepointer,para_offset-pushedparasize);
|
||||||
|
concatcopy(tempreference,r^,4,false,false);
|
||||||
|
end
|
||||||
|
else
|
||||||
|
emit_push_mem(tempreference);
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
emit_push_mem(tempreference);
|
begin
|
||||||
|
if p^.resulttype^.size>0 then
|
||||||
|
begin
|
||||||
|
inc(pushedparasize,2);
|
||||||
|
if inlined then
|
||||||
|
begin
|
||||||
|
r:=new_reference(procinfo^.framepointer,para_offset-pushedparasize);
|
||||||
|
concatcopy(tempreference,r^,2,false,false);
|
||||||
|
end
|
||||||
|
else
|
||||||
|
exprasmlist^.concat(new(paicpu,op_ref(A_PUSH,S_W,newreference(tempreference))));
|
||||||
|
end;
|
||||||
|
end;
|
||||||
end
|
end
|
||||||
{ call by value open array ? }
|
{ call by value open array ? }
|
||||||
else
|
else
|
||||||
@ -3396,7 +3414,10 @@ procedure mov_reg_to_dest(p : ptree; s : topsize; reg : tregister);
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.52 1999-10-08 15:40:47 pierre
|
Revision 1.53 1999-10-13 22:09:29 pierre
|
||||||
|
* fix for uggly bug of Marco
|
||||||
|
|
||||||
|
Revision 1.52 1999/10/08 15:40:47 pierre
|
||||||
* use and remember that C functions with complex data results use ret $4
|
* use and remember that C functions with complex data results use ret $4
|
||||||
|
|
||||||
Revision 1.51 1999/10/05 22:01:52 pierre
|
Revision 1.51 1999/10/05 22:01:52 pierre
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user