fix(lua): expose missing functions
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
parent
56344c0541
commit
5a01f167df
4 changed files with 4 additions and 2 deletions
|
@ -25,7 +25,7 @@ options & to_options(lua_State * L, int idx) {
|
|||
return *static_cast<options*>(luaL_checkudata(L, idx, options_mt));
|
||||
}
|
||||
|
||||
static int push_options(lua_State * L, options const & o) {
|
||||
int push_options(lua_State * L, options const & o) {
|
||||
void * mem = lua_newuserdata(L, sizeof(options));
|
||||
new (mem) options(o);
|
||||
luaL_getmetatable(L, options_mt);
|
||||
|
|
|
@ -11,5 +11,6 @@ class options;
|
|||
void open_options(lua_State * L);
|
||||
bool is_options(lua_State * L, int idx);
|
||||
options & to_options(lua_State * L, int idx);
|
||||
int push_options(lua_State * L, options const & o);
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -16,7 +16,7 @@ Author: Leonardo de Moura
|
|||
namespace lean {
|
||||
constexpr char const * sexpr_mt = "sexpr.mt";
|
||||
|
||||
static int push_sexpr(lua_State * L, sexpr const & e) {
|
||||
int push_sexpr(lua_State * L, sexpr const & e) {
|
||||
void * mem = lua_newuserdata(L, sizeof(sexpr));
|
||||
new (mem) sexpr(e);
|
||||
luaL_getmetatable(L, sexpr_mt);
|
||||
|
|
|
@ -11,5 +11,6 @@ class sexpr;
|
|||
void open_sexpr(lua_State * L);
|
||||
bool is_sexpr(lua_State * L, int idx);
|
||||
sexpr & to_sexpr(lua_State * L, int idx);
|
||||
int push_sexpr(lua_State * L, sexpr const & e);
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue