Re: [fpc-pascal] Dynamic Arrays in Procedures

2020-10-04 Thread Sven Barth via fpc-pascal
James Richters via fpc-pascal schrieb am So., 4. Okt. 2020, 23:44: > So it does... > > I should have tested my own example. I found my problem, I declared it > as Var and it would only work with variables due to that > That's just a normal open array parameter and worked this way for a long ti

Re: [fpc-pascal] Dynamic Arrays in Procedures

2020-10-04 Thread Winfried Bartnick via fpc-pascal
: Sunday, October 4, 2020 4:34 PM To: fpc-pascal@lists.freepascal.org Cc: gabor Subject: Re: [fpc-pascal] Dynamic Arrays in Procedures W dniu 2020-10-04 o 21:58, James Richters via fpc-pascal pisze: DoSomethingElse([$12,$1A,$2B]);for example… of course this doesn’t work, but is there a syntax that

Re: [fpc-pascal] Dynamic Arrays in Procedures

2020-10-04 Thread James Richters via fpc-pascal
@lists.freepascal.org Cc: gabor Subject: Re: [fpc-pascal] Dynamic Arrays in Procedures W dniu 2020-10-04 o 21:58, James Richters via fpc-pascal pisze: > DoSomethingElse([$12,$1A,$2B]);for example… of course this doesn’t > work, but is there a syntax that would work? This expression works fine with FPC

Re: [fpc-pascal] Dynamic Arrays in Procedures

2020-10-04 Thread gabor via fpc-pascal
W dniu 2020-10-04 o 21:58, James Richters via fpc-pascal pisze: DoSomethingElse([$12,$1A,$2B]);for example… of course this doesn’t work, but is there a syntax that would work? This expression works fine with FPC 3.2.0 ___ fpc-pascal maillist - fpc-p

Re: [fpc-pascal] Dynamic Arrays in Procedures

2020-10-04 Thread Howard Page-Clark via fpc-pascal
On 04/10/2020 20:58, James Richters via fpc-pascal wrote: I’m wondering if there is a way to pass an array of values to a Procedure without defining an array variable…. For example, if I have a Procedure: Procedure DoSomething(X :Byte); Then I can call it with a specific a variable like thi

[fpc-pascal] Dynamic Arrays in Procedures

2020-10-04 Thread James Richters via fpc-pascal
I'm wondering if there is a way to pass an array of values to a Procedure without defining an array variable.. For example, if I have a Procedure: Procedure DoSomething(X :Byte); Then I can call it with a specific a variable like this: Var ThingA :Byte; . DoSomething(ThingA); And