Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-26 Thread silvioprog
On Tue, Jan 26, 2016 at 5:36 AM, leledumbo wrote: > > AFAIR it was supported until certain FPC version > > Found it: > > http://wiki.lazarus.freepascal.org/User_Changes_2.6.0#Array_of_const_parameters_and_cdecl_routines Thanks for the link. I didn't see this Remedy: "Remove the cdecl specifier

Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-26 Thread silvioprog
On Tue, Jan 26, 2016 at 5:34 AM, leledumbo wrote: > > Neither FPC nor Delphi allow you to declare your own varargs functions. > That it works in Delphi is by pure change. Trying to outsmart the compiler > will only lead to trouble. > > AFAIR it was supported until certain FPC version, but the dro

Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-26 Thread silvioprog
On Mon, Jan 25, 2016 at 4:05 AM, Sven Barth wrote: > Am 25.01.2016 04:42 schrieb "silvioprog" : > > What I'm doing wrong? Can I use this callings on FPC in the DELPHI > mode?! :-/ > > Neither FPC nor Delphi allow you to declare your own varargs functions. > That it works in Delphi is by pure chan

Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-26 Thread Jonas Maebe
leledumbo wrote: > AFAIR it was supported until certain FPC version Found it: http://wiki.lazarus.freepascal.org/User_Changes_2.6.0#Array_of_const_parameters_and_cdecl_routines As that entry notes, it was not supported: "There is however no way in (Free) Pascal to access these arguments on

Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-26 Thread Jonas Maebe
Sven Barth wrote: Am 25.01.2016 04:42 schrieb "silvioprog" mailto:silviop...@gmail.com>>: > What I'm doing wrong? Can I use this callings on FPC in the DELPHI mode?! :-/ Neither FPC nor Delphi allow you to declare your own varargs functions. That it works in Delphi is by pure change. It will

Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-26 Thread leledumbo
> AFAIR it was supported until certain FPC version Found it: http://wiki.lazarus.freepascal.org/User_Changes_2.6.0#Array_of_const_parameters_and_cdecl_routines -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/SIGSEGV-when-using-varargs-calling-tp5723661p5723670

Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-26 Thread leledumbo
> Neither FPC nor Delphi allow you to declare your own varargs functions. That it works in Delphi is by pure change. Trying to outsmart the compiler will only lead to trouble. AFAIR it was supported until certain FPC version, but the dropped entirely to only for external C functions. The related e

Re: [fpc-pascal] SIGSEGV when using varargs calling

2016-01-24 Thread Sven Barth
Am 25.01.2016 04:42 schrieb "silvioprog" : > What I'm doing wrong? Can I use this callings on FPC in the DELPHI mode?! :-/ Neither FPC nor Delphi allow you to declare your own varargs functions. That it works in Delphi is by pure change. Trying to outsmart the compiler will only lead to trouble.

[fpc-pascal] SIGSEGV when using varargs calling

2016-01-24 Thread silvioprog
Hello, Consider the following types: TPuts1 = procedure; cdecl varargs; TPuts2 = procedure(par: string); cdecl varargs; TPuts3 = procedure(const par: string); cdecl varargs; this procedure: procedure Puts(par1, par2, par3: string); cdecl; begin Write(par1, ' '); Write(par2, '