diff --git a/src/bindings/lua/name.cpp b/src/bindings/lua/name.cpp index c7cf26f64..582ef1ba6 100644 --- a/src/bindings/lua/name.cpp +++ b/src/bindings/lua/name.cpp @@ -84,7 +84,7 @@ static int name_lt(lua_State * L) { return 1; } -void init_name(lua_State * L) { +void open_name(lua_State * L) { luaL_newmetatable(L, "name.mt"); setfuncs(L, name_m, 0); diff --git a/src/bindings/lua/name.h b/src/bindings/lua/name.h index fd374e465..9f6f5ec21 100644 --- a/src/bindings/lua/name.h +++ b/src/bindings/lua/name.h @@ -7,6 +7,6 @@ Author: Leonardo de Moura #ifdef LEAN_USE_LUA #include namespace lean { -void init_name(lua_State * L); +void open_name(lua_State * L); } #endif diff --git a/src/bindings/lua/numerics.cpp b/src/bindings/lua/numerics.cpp index 3f06fd1ae..cfca1a3e4 100644 --- a/src/bindings/lua/numerics.cpp +++ b/src/bindings/lua/numerics.cpp @@ -98,7 +98,7 @@ public: return push_result(L, arg); } - static void init(lua_State * L) { + static void open(lua_State * L) { luaL_newmetatable(L, M); setfuncs(L, m, 0); @@ -124,14 +124,14 @@ const struct luaL_Reg num_bindings::m[] = { constexpr char const mpz_name[] = "mpz"; constexpr char const mpz_metatable[] = "mpz.mt"; -void init_mpz(lua_State * L) { - num_bindings::init(L); +void open_mpz(lua_State * L) { + num_bindings::open(L); } constexpr char const mpq_name[] = "mpq"; constexpr char const mpq_metatable[] = "mpq.mt"; -void init_mpq(lua_State * L) { - num_bindings::init(L); +void open_mpq(lua_State * L) { + num_bindings::open(L); } } #endif diff --git a/src/bindings/lua/numerics.h b/src/bindings/lua/numerics.h index 7e95c2160..2f100bc74 100644 --- a/src/bindings/lua/numerics.h +++ b/src/bindings/lua/numerics.h @@ -7,7 +7,7 @@ Author: Leonardo de Moura #ifdef LEAN_USE_LUA #include namespace lean { -void init_mpz(lua_State * L); -void init_mpq(lua_State * L); +void open_mpz(lua_State * L); +void open_mpq(lua_State * L); } #endif diff --git a/src/shell/lua/leanlua.cpp b/src/shell/lua/leanlua.cpp index 21dde2884..fe3cfa901 100644 --- a/src/shell/lua/leanlua.cpp +++ b/src/shell/lua/leanlua.cpp @@ -18,9 +18,9 @@ int main(int argc, char ** argv) { int exitcode = 0; L = luaL_newstate(); luaL_openlibs(L); - lean::init_name(L); - lean::init_mpz(L); - lean::init_mpq(L); + lean::open_name(L); + lean::open_mpz(L); + lean::open_mpq(L); for (int i = 1; i < argc; i++) { status = luaL_loadfile(L, argv[i]);