|
@@ -1307,7 +1307,8 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
|
|
procedure tasmlisttypedconstbuilder.parse_procvardef(def:tprocvardef);
|
|
procedure tasmlisttypedconstbuilder.parse_procvardef(def:tprocvardef);
|
|
var
|
|
var
|
|
tmpn,n : tnode;
|
|
tmpn,n : tnode;
|
|
- pd : tprocdef;
|
|
|
|
|
|
+ pd : tprocdef;
|
|
|
|
+ procaddrdef: tprocvardef;
|
|
havepd,
|
|
havepd,
|
|
haveblock: boolean;
|
|
haveblock: boolean;
|
|
begin
|
|
begin
|
|
@@ -1349,7 +1350,8 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
|
|
{ in case of a nested procdef initialised with a global routine }
|
|
{ in case of a nested procdef initialised with a global routine }
|
|
ftcb.maybe_begin_aggregate(def);
|
|
ftcb.maybe_begin_aggregate(def);
|
|
{ to handle type conversions }
|
|
{ to handle type conversions }
|
|
- ftcb.queue_init(def);
|
|
|
|
|
|
+ procaddrdef:=cprocvardef.getreusableprocaddr(def);
|
|
|
|
+ ftcb.queue_init(procaddrdef);
|
|
{ remove typeconvs, that will normally insert a lea
|
|
{ remove typeconvs, that will normally insert a lea
|
|
instruction which is not necessary for us }
|
|
instruction which is not necessary for us }
|
|
while n.nodetype=typeconvn do
|
|
while n.nodetype=typeconvn do
|
|
@@ -1403,7 +1405,7 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
|
|
end
|
|
end
|
|
else if n.nodetype=pointerconstn then
|
|
else if n.nodetype=pointerconstn then
|
|
begin
|
|
begin
|
|
- ftcb.queue_emit_ordconst(tpointerconstnode(n).value,def);
|
|
|
|
|
|
+ ftcb.queue_emit_ordconst(tpointerconstnode(n).value,procaddrdef);
|
|
if not def.is_addressonly then
|
|
if not def.is_addressonly then
|
|
ftcb.emit_tai(Tai_const.Create_sym(nil),voidpointertype);
|
|
ftcb.emit_tai(Tai_const.Create_sym(nil),voidpointertype);
|
|
end
|
|
end
|