lua-users home
lua-l archive

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

在 2011-6-26 半夜12:41,"steve donovan" <>写道:
> On Sat, Jun 25, 2011 at 6:18 PM, Xavier Wang <> wrote:
> > Sorry, but I mean, a new version of assert against the baselib one that
> > _don't_ evaluate the second _expression_ if the first _expression_ is true.
> That is difficult because assert() is a function, not a macro like in C.
> It's a pity that expressions cannot be statements, e.g. the _expression_
> 1 == 0 or error_fn()
> works as we want: error_fn() is only called if the first condition fails.
Thank you! That is new to me, and very useful!!