Originally Posted By: argv0
I think this suggestion in particular is an exercise in form, not function, and misses the point. The classical benefit of a foreach() construct is to allow enumeration via a unified interface for any object/data. Specifically, it allows user-types to be enumerated in the same way builtin-types would be, which is kind of useless in a non-typed language to begin with. Moreover, if you have to pass contextual switches based on the data type, you lose the unified interface and all you're left with is a construct that saves a few keystrokes. Is this really just about vanity?


100% agree. I don't see any satisfiable way of including a "foreach" loop in mIRC's languages which denotes everything as a space delimited string. Not going to work.

Quote:
Let's look at this another way: "while" can do everything mentioned in this thread in roughly the same number of bytes. Why don't we have a discussion about what's wrong with while loops first, and then maybe Khaled can understand the real problem at hand, without resorting to feature creep in the parser.


This is EXACTLY what people would say about using GOTO for looping before the while syntax was added. EXACTLY!


Beware of MeStinkBAD! He knows more than he actually does!