* handle cdecl varargs parameters in llvm procdef string representations

git-svn-id: branches/hlcgllvm@28355 -
This commit is contained in:
Jonas Maebe 2014-08-10 13:19:24 +00:00
parent 9225d43ccf
commit bae1f72896

View File

@ -519,6 +519,16 @@ implementation
signext: tllvmvalueextension;
usedef: tdef;
begin
if (proccalloption in cdecl_pocalls) and
is_array_of_const(hp.vardef) then
begin
if not first then
encodedstr:=encodedstr+', '
else
first:=false;
encodedstr:=encodedstr+'...';
exit
end;
paraloc:=hp.paraloc[calleeside].location;
repeat
usedef:=paraloc^.def;
@ -600,6 +610,12 @@ implementation
hp:=tparavarsym(def.paras[paranr]);
llvmaddencodedparaloctype(hp,def.proccalloption,pddecltype in [lpd_decl],first,encodedstr);
end;
if po_varargs in def.procoptions then
begin
if not first then
encodedstr:=encodedstr+', ';
encodedstr:=encodedstr+'...';
end;
encodedstr:=encodedstr+')'
end;