On Wed, Sep 11, 2019 at 7:06 AM Ralf Quint wrote:
> On 9/10/2019 4:26 PM, wkitt...@windstream.net wrote:
> > On 9/9/19 10:11 AM, James Richters wrote:
> >> Pascal doesn't have things like step...
> >
> > hunh??? i don't think that's right but i'm just catching up after
> > several 10+ hours days
Christo Crause schrieb am Mi., 11. Sep. 2019,
09:54:
>
> On Wed, Sep 11, 2019 at 7:06 AM Ralf Quint wrote:
>
>> On 9/10/2019 4:26 PM, wkitt...@windstream.net wrote:
>> > On 9/9/19 10:11 AM, James Richters wrote:
>> >> Pascal doesn't have things like step...
>> >
>> > hunh??? i don't think that's
I am not aware of any Pascal implementation that does have a STEP
parameter for FOR loops
If step is wanted, it's easy enough:
For n:=a to b Do
Begin
if n Mod step <> 0 then Continue;
...
Martin.
___
fpc-pascal maillist - fpc-pascal@lis
If step is wanted, it's easy enough:
For n:=a to b Do
Begin
if n Mod step <> 0 then Continue;
...
p.s. make that
if (n-a) Mod step <> 0 then Continue;
for cases where a is not a multiple of step.
Martin.
___
fpc-pascal maillist -
How do you get ‘By’ to work? I have downto working but if I try ‘By’ I get
Fatal: Syntax error, "DO" expected but "identifier BY" found
If FPC is going to support downto and by, why not also support changing the
control variable when not in {$Mode TP} as well, and just make a note that
I don't know what the syntax would be if it did have a way to do a step
https://wiki.lazarus.freepascal.org/FOR..DO
"In Pascal, the for loop can only count in increments (steps) of 1"
James
-Original Message-
From: fpc-pascal On Behalf Of
wkitt...@windstream.net
Sent: Tuesday, Septemb
James Richters schrieb am Mi., 11. Sep.
2019, 16:24:
> How do you get ‘By’ to work? I have downto working but if I try ‘By’ I
> get
>
>
>
> Fatal: Syntax error, "DO" expected but "identifier BY" found
>
Did you see anywhere that said that this bug report was resolved and the
patch integrated i
Yes, off topic. The initial poster's code had the loop variable declared as an initialized constant. Not as a true variable. No FPC in hand, I can't test if setting 'assignable typed constants = true' would permit the use of an initialized typed constant or not. Sent from my Huawei phone Or
Actually, the original code used two VARs, not typed CONST. One VAR was
initialized and one was not. I think this is a bug and should be fixed.
As Jonas already pointed out:
"var i : longint = 0;" is internally handled using the same code path as
"const i : longint = 0", and typed constants c
I reported it here:
https://bugs.freepascal.org/view.php?id=36065
James
>Actually, the original code used two VARs, not typed CONST. One VAR was
>initialized and one was not. I think this is a bug and should be fixed.
>As Jonas already pointed out:
>"var i : longint = 0;" is interna
On 9/11/19 1:06 AM, Ralf Quint wrote:
On 9/10/2019 4:26 PM, wkitt...@windstream.net wrote:
On 9/9/19 10:11 AM, James Richters wrote:
Pascal doesn't have things like step...
hunh??? i don't think that's right but i'm just catching up after several 10+
hours days of $job...
i know that i've
11 matches
Mail list logo