lua-users home
lua-l archive

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

On Tue, Nov 17, 2009 at 2:02 PM, Juris Kalnins <> wrote:
>  while #x do break end
>  do local _ = #x end
>  (function () return #x end)()

OK, assuming that '#' stands not for its usual meaning (in which case
first statement always returns immediately)

The second is definitely the best; is the idea to execute the
operation for its side-effect? Why go to the trouble of wrapping this
in a function?