View Single Post
04-04-09, 03:46 PM   #39
Shadowed
...
Premium Member
Featured
Join Date: Feb 2006
Posts: 387
Originally Posted by Aezay View Post
To save a function call, many uses next() as the iterater in a for loop, why not do the same for ipairs(), should be easily obtainable using this code. Or is there an iterator function already available for array type tables, like next?
This would probably be quite silly normally, unless it's code run often like in an OnUpdate script.

Code:
local iterator = ipairs(_G);
I think I've seen maybe one or two people use next, I'm not sure I would call it common at all. This gets into premature/unnecessary optimization
  Reply With Quote