lua-users home
lua-l archive

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


On Fri, Jan 17, 2014 at 7:57 PM, Andrew Starks <andrew.starks@trms.com> wrote:
>
> On Fri, Jan 17, 2014 at 10:54 AM, Dirk Laurie <dirk.laurie@gmail.com> wrote:
>>
>> Well, now, this sort of question is not that hard to answer.
>> Take a look at lbaselib.c.
>
>
> I think we can take "thought assert() called error()" to mean "assumed
> assert()...".
>
> In which case, it's merely as statement of expectation and inadvertently
> also a statement
> of how seldom it comes up?
>
> My assumption is that a change in behavior here might be a problem for lots
> of existing code?

How could it be? You have already errored at this point, it is just a
matter of which error you see.

> Also, rewriting assert in C (if speed is super-critical) wouldn't be hard
> and wrapping it is trivial. So as in all things lua, if you don't like it...
> :)

Sure wrapping it is easy, but assert is often used in interactive
sessions and examples.

Justin