lua-users home
lua-l archive

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


On 1 October 2013 23:47, Luiz Henrique de Figueiredo <lhf@tecgraf.puc-rio.br> wrote:
>
> > lua-sophia [1] is a Lua binding to the Sophia [2] key-value database,
> > claiming high performance.
>
> Nice. You may want to try adding a proxy table as in my lgdbm so that
> you can write t[k]=v and update the database, and t[k] to query it.

Yes, it is on my TODO list to provide a Lua-style interface to the database. The question remains on how/whether to handle other class methods efficiently in __index, since I want to use it for "t[k]".

> If you're targeting Lua 5.2, you can use luaL_setmetatable instead of
> luaL_getmetatable+lua_setmetatable and define luaL_setmetatable if
> LUA_VERSION_NUM < 502.
 
I develop primary for Lua 5.1, but want to have it "Lua 5.2 ready". I tried compiling it under Lua 5.2 and there are some other outstanding issues. Thank you for the suggestion.