Re: [fpc-pascal] Pass type as function parameter

2021-03-24 Thread Darius Blaszyk via fpc-pascal
Thank you so much Michael! On Wed, Mar 24, 2021 at 11:05 AM Michael Van Canneyt wrote: > > > On Wed, 24 Mar 2021, Darius Blaszyk via fpc-pascal wrote: > > > Hi, > > > > Would it be possible in FPC to pass a type of a variable as a parameter > to > > a function? > > > > e.g. > >

Re: [fpc-pascal] Pass type as function parameter

2021-03-24 Thread Marco van de Voort via fpc-pascal
Op 2021-03-24 om 11:05 schreef Michael Van Canneyt via fpc-pascal: Would it be possible in FPC to pass a type of a variable as a parameter to a function? e.g.  MyFunction(integer); I have legacy C code that does this via a macro. Hopefully, it can be done so I do not need to change the

Re: [fpc-pascal] Pass type as function parameter

2021-03-24 Thread Michael Van Canneyt via fpc-pascal
On Wed, 24 Mar 2021, Darius Blaszyk via fpc-pascal wrote: Hi, Would it be possible in FPC to pass a type of a variable as a parameter to a function? e.g. MyFunction(integer); I have legacy C code that does this via a macro. Hopefully, it can be done so I do not need to change the existing

[fpc-pascal] Pass type as function parameter

2021-03-24 Thread Darius Blaszyk via fpc-pascal
Hi, Would it be possible in FPC to pass a type of a variable as a parameter to a function? e.g. MyFunction(integer); I have legacy C code that does this via a macro. Hopefully, it can be done so I do not need to change the existing code too badly. TIA Rgds, Darius