News for hackers. Stuff that matters.
Re:Lua: Good, bad, and ugly parts by Stratoscope on Saturday March 09, 2013 @07:58PM (#5350215)
1 is not the same value as true. Just as in the case I commented on a couple of messages above, 1 and true are two different types.

The == operator does not compare the "truthiness" of two values. It compares the values, and if those values are two different types, they are always unequal.

http://www.lua.org/pil/3.2.html

Re:Lua: Good, bad, and ugly parts by vor_ on Saturday March 09, 2013 @08:09PM (#5350246)
I'm aware of the reasons why. It's still inconsistent to users. Remember that Lua is targeted at non-professional programmers.
Re:Lua: Good, bad, and ugly parts by jmaygarden on Saturday March 09, 2013 @08:38PM (#5350332)
In my opinion, having (1==true) evaluated to true, but (2==true) evaluate to false is more inconsistent. Even non-professionals should follow logic if they are going to program.