[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Zero as False
- From: Paige DePol <lual@...>
- Date: Tue, 19 Nov 2013 19:43:16 -0600
> On Nov 19, 2013, at 7:27 PM, Tim Hill <drtimhill@gmail.com> wrote:
>
> As has been noted, I don’t think “0 == false” should be true anyway .. in current Lua “nil == false” is also false. It’s important not to confuse “false-ness” with the value “false”.
>
> —Tim
Personally, I believe 0 should be equal to false and everything else should be equal to true. nil, being a special case, is false when compared to anything else other than nil.
In all my experience coding the values 0 and 1 have pretty much been the definitions of false and true. So having 0 == false, to me, just makes sense, and makes everything work as I would expect it to.
I appreciate your position, though I think I will be sticking with the patch as-is for LUNiA, I like my numeric zeros to be equivalent to boolean false in every way. :)
~pmd~
- References:
- Zero as False, Paige DePol
- Re: Zero as False, Paige DePol
- Re: Zero as False, Paige DePol
- Re: Zero as False, Daurnimator
- Re: Zero as False, Rena
- Re: Zero as False, Paige DePol
- Re: Zero as False, Coda Highland
- Re: Zero as False, Paige DePol
- Re: Zero as False, Coda Highland
- Re: Zero as False, Paige DePol
- Re: Zero as False, Tim Hill