I believe in Delphi only external functions may use varargs. In your case you are declaring a variable, which could be assigned to a local function.
function FmtStr(const fmt: PAnsiChar): PAnsiChar; varargs; cdecl; external yourlibname; Note: varargs comes before cdecl, though I am not sure if it matters.
_______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal