lua-users home
lua-l archive

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


----- Original Message -----
From: "Roberto Ierusalimschy" <roberto@inf.puc-rio.br>
Sent: Tuesday, September 26, 2000 2:12 AM
Subject: Re: tag methods question
>
> With
> set/getglobal tag methods, we can have different methods for different
> kinds of globals.

Again, this can be done with only table tag methods.  The gettable tag
method can look up the tag method of the value being set just as is done now
for globals.  Or not... the nice thing would be that the decision would be
in the hands of the programmer writing the extension.  I could do so much
with Lua extensions if only this change were made...

To state simply the problem we have now, the following two statements
produce different results because different tag methods are called.  Is this
good?

    a = 5
    globals().a = 5


Regards,
-John