> "Don’t be so quick to complain; you finally got ‘for each’ 10 years after
> the rest of the world (including Active4D).”
> Good point. So…you’re thinking that the feature set is complete?

Absolutely. In fact it is more complete than most implementations, you can 
specify and begin and end index for ordered collections.


> "I don’t know of a single language (and I have used at least 6) where ‘for
> each’ is reversible.”
> This could be 4D’s chance to be a trendsetter!

I don’t think it's worth it. Iterating in reverse is not a common operation.


> it’s funny that we have such a handy looping construct yet I have write
> code to init and update my own index.

If you need an index in a ‘for each’ loop, you should actually be using an 
indexed ‘for’ loop. That’s the point of having ‘for each’ separate from ‘for’: 
90% of the time you don’t need the index and ‘for each’ is more concise, but 
when you need an index a for loop increments it for you.

- Aparajita

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**********************************************************************

Reply via email to