lua-users home
lua-l archive

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

于 2013-10-15 4:05, Thijs Schreijer 写道:

-----Original Message-----
From: [] On
Behalf Of John Hind
Sent: maandag 14 oktober 2013 16:18
Subject: Re: Proposal: add all metamethods to the 2.4 section

Date: Mon, 14 Oct 2013 08:17:55 -0300
From: Luiz Henrique de Figueiredo <>
Subject: Re: Proposal: add all metamethods to the 2.4 section

On the 2.4 section of the reference manual some metamethods are
explained but not all.
It would be great to see all the methods available at a glance, for
instance missing methods are :
Execpt for __gc, the others are what we call "core metamethods": they
are features of the libraries.

For what it is worth I strongly agree with the OP on this (and have
mentioned it before myself). It does not need to be lengthy: just a list
the keys cross-referenced and hyperlinked to the section in the manual
they are fully described would be fine. At present there is no complete
of the keys used in the standard distribution (core and libraries), not
in the index. This makes it difficult when one is designing an object:
like to consider all the existing meta-keys for possible relevance and to
sure if adding more that existing ones are not being "stomped on".

  +1 for me to. There have been more than one occasion at which I missed such a simple listing of meta methods in the documentation.

Me too. The reference manual really should have such a list.

BTW, when I was learn Lua long ago, I was expecting such a list to be there in the manual.
I once occasionally found such things in a document named luarefv51.html coming with L4W.
I find this online version of the document[1], in case it might be useful for anyone.