lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On 01/23/2011 12:00 AM, David Manura wrote:
On Sat, Jan 22, 2011 at 10:06 PM, dcharno<dcharno@comcast.net>  wrote:
I found it interesting that continue is used in 55 places in Lua 5.1.4 ;)

IIRC, at least some of those uses of continue simulate tail-calls
(which Lua implements but C does not).  When I ported the string
library to Lua [1], the `continue` statements there were more
appropriately re-expressed in Lua as tail calls.

[1] http://lua-users.org/wiki/StringLibraryInLua

Before the hate mate starts rolling in, I'll say I meant it partially as a joke and partially as a way of saying continue is a tool that's useful in some cases. I'm sure all of the continue statements could be removed from any specific source tree.