QB64.org Forum

Active Forums => QB64 Discussion => Topic started by: Pete on January 06, 2019, 07:23:12 am

Title: We lost the nested NEXT somewhere in the version updtes... [UPDATE: we didn't]
Post by: Pete on January 06, 2019, 07:23:12 am
QB45 could do nested FOR/NEXT statements, and some prior versions of QB64 could, but not the more recent versions.

I think someone eliminated it, because it presents an asymmetrical alignment problem for the IDE!

so...

FOR i = 1 TO 5
    FOR j = 1 TO 10
    next i, j

cannot be used anymore. No biggie to me, but it should at least be updated in the WIKI...

http://qb64.org/wiki/NEXT

4th bullet down under description heading.

Pete

 
Title: Re: We lost the nested NEXT somewhere in the version updtes...
Post by: luke on January 06, 2019, 07:40:37 am
You need to get the variable order correct: NEXT j, i

I edited the dotpoint on the wiki to use this order.
Title: Re: We lost the nested NEXT somewhere in the version updtes... [UPDATE: we didn't]
Post by: Pete on January 06, 2019, 12:02:10 pm
Thanks! I hadn't used that in ages. I just use NEXT without the variable. I tried it in the IDE and it even aligns the code indentation properly, no matter the method... next j, i... next: next... etc.

Pete