[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua 5.3 changes to .__eq
- From: Coda Highland <chighland@...>
- Date: Sun, 12 Jul 2015 05:55:18 -0700
On Sun, Jul 12, 2015 at 5:20 AM, Peter Aronoff <telemachus@arpinum.org> wrote:
> Hi,
>
> I'm a little confused abut the changes to .__eq in Lua 5.3. Now that Lua will
> call the first .__eq found if *either* of the two operands to == has a defined
> .__eq method, some odd results seem to follow. In particular, == is now order
> dependent. x == y and y == x can return different results. Is this really
> desirable?
Consider that the operation wasn't commutative before, either, in the
case where __eq was defined on one and not the other.
/s/ Adam