lua-users home
lua-l archive

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


I'm sorry my post was so boring.

I guess you are referring to your posts from 21/1/2022, which do
describe the same problem.

Yes I think there are probably many instances where this feature would
be useful, not just for writing big integer libraries!

Any library making use of tables or userdata to represent user-defined
data types could make use of this feature to allow these objects to be
compared with Lua's inbuilt data types (string, number, boolean).

But as I said I don't see any future in changing the semantics of the
existing __eq metamethod.


On 09/06/2022 15:32, Flyer31 Test wrote:
Your description is a bit long, I did not read it in any detail.

But if I understand you, I had the same problem when I did my StrLib
"static string" library for low-RAM Lua applications in IoT range... .
There I finally also wanted to be able to compare my "sb-items" (made
by meta) to normal strings with ==.

Please check my posts concerning this some months ago.

It is a quite small change in a lua source file, that you have to do,
I have described it there in detail.

On Wed, Jun 8, 2022 at 3:07 PM Andrew <> wrote:

Hello All,

there is currently a small but annoying problem when constructing
numerical objects based on tables or userdata.