lua-users home
lua-l archive

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


On Sat, Jun 25, 2011 at 16:24, Rebel Neurofog <rebelneurofog@gmail.com> wrote:
>> function assert(cond, err)
>>  if cond then return cond
>>  else error(err or "assertion failed")
>>  end
>> end
>
> Not excactly. This one is closer:
>
> function assert(cond, err, ...)
>  if cond then return cond, err, ...
>  else error(err or "assertion failed")
>  end
> end
>
>

Whoops, good catch.

-- 
Sent from my toaster.