Hi all,
I have found a problem with 'array of const'. There are two types: The array of variant records and the C-Compiler array used by the 'cdecl;external;'. The compiler allows to put the former into the latter, but it does not convert it correctly. See the program below.
Is there a workaround?
program printftest;
{$mode objfpc}{$H+}
procedure printf(fm: pchar; args: array of const); cdecl; external 'c';
procedure print(i: integer; fm: pchar; args: array of const);
begin
printf(fm,args);
end;
begin
print(0,'a number %i '#13#10,[3333]);
end.Mattias
