This first edition was written for Lua 5.0. While still largely relevant for Lua 5.1, there are some differences.
The second edition targets Lua 5.1 and is available at Amazon and as an e-book.
By buying the book, you also help to support the Lua project.
Programming in Lua | ||
Part I. The Language Chapter 7. Iterators and the Generic for |
In this chapter, we cover how to write iterators for the generic for. We start with simple iterators, then we learn how to use all the power of the generic for to write more efficient iterators.
Copyright © 2003–2004 Roberto Ierusalimschy. All rights reserved. |