|
if str = S:Next() then end end doesnt work? Its not the beeest est code, but i dont have more sources....----- Original Message ----- From: "Michael Newberry" <mnewberry@mirametrics.com>
To: "Lua list" <lua@bazar2.conectiva.com.br> Sent: Monday, January 08, 2007 6:33 PM Subject: what's wrong with this loop syntax?
Pardon me for asking a simple question, but why can't I use this syntax? while (str = S:Next()) ~= nil do or this syntax: while (str = S:Next()) and str ~= nil do where S exists and S:Next() returns a string or nil. I get this message: `)' expected near `=' Thanks, Michael