Code: Select all
Global NewList foo()
For i = 1 To 10
AddElement(foo()) : foo() = i
Next i
Procedure FindFoo(int)
ForEach foo()
If foo() = int
ProcedureReturn @foo()
EndIf
Next
EndProcedure
ForEach foo()
Debug foo()
FindFoo(5)
Next
I'm wondering if you guys had some safety net to avoid that. I'm tempted to Push/PopListPosition() every time after ForEach and before Next, with a custom macro... or just be careful




