Module macro.forall
forall statement.
The syntax is forall VAR SELECT [if CONDN] do where
SELECT is either in TBL or = START,FINISH
For example,
forall name in {'one','two'} do print(name) end
forall obj in get_objects() if obj:alive() then
obj:action()
end
Using forall, we also define list comprehensions like
L{s:upper() | s in names if s:match '%S+'}
Macros
| forall | extended for statement. |
| L | list comprehension. |