lua-users home
lua-l archive

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


On Mon, Oct 7, 2019 at 10:48 PM Petri Häkkinen wrote:

> So, the motivation for the change is to move our minds from the
> concept that errors return (nil,msg) to the concept that errors return
> (falsy,msg). Maybe one day in the distant future we might change
> that falsy to false instead of nil.

I’m sorry but I fail to see any improvement here. How does false signal an error any better than nil?


Probably, Roberto wants to guarantee that an array  {any_standard_function()}  will be a sequence.
Hence such array will become traversable with ipairs.
This might reduce nilophoby in Lua :-)