lua-users home
lua-l archive

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


On 24 Mar 2004, at 22:36, RLake@oxfam.org.pe wrote:

If I understand you correctly, you are trying to use rawset on a userdata. That will not work, you can only rawset a real table.
Okay, I see the problem now.  So... how does one go about handling the 
__newindex metamethod on a userdata?  Basically I'd like the event to 
be processed normally, that is, the intended assignment should still 
take place.  I just have to inspect the key and the value and increment 
some counters.
It may be that Lunar is not sufficient to your needs, or at least requires some modification.
I'd be glad to modify the interface myself, but I'm afraid I'd need at 
least some general directions -- I have 14 years experience in C++ but 
only 2 months in Lua...
Thank you,
Dario