[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: "attempt to compare number with userdata"
- From: Nikolai Kondrashov <Nikolai.Kondrashov@...>
- Date: Mon, 24 Nov 2008 17:53:42 +0300
Peter Cawley wrote:
>>From the manual: " The function |getcomphandler| defines how Lua
> chooses a metamethod for comparison operators. A metamethod only is
> selected when both objects being compared have the same type and the
> same metamethod for the selected operation." Hence userdata cannot be
> compared to non-userdata without modifing the Lua source.
Thank you. Well, I've seen it. I'm actually asking about the reasons for
that and also where (approximately) should I modify the Lua sources if there
is no reasons.
Sincerely,
Nick