TMP: Brain broke, I need a break, don't use this commit
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
|
||||
|
||||
```toy
|
||||
for (var name in array) {
|
||||
//
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
pushStack name
|
||||
pushStack array
|
||||
pushStack counter //tracks the index for each loop
|
||||
|
||||
OPCODE iterable:
|
||||
pushScope
|
||||
declare name = array.next() if next is not null else jump to end
|
||||
|
||||
(user code)
|
||||
|
||||
popScope
|
||||
jump to beginning
|
||||
|
||||
popStack counter, array, name
|
||||
Reference in New Issue
Block a user