[Tarantool-patches] [PATCH 33/43] build: export src/lua/error.c symbols

Vladislav Shpilevoy v.shpilevoy at tarantool.org
Sun Apr 12 03:13:15 MSK 2020


Exports a function used by the public C API.

Part of #2971
---
 extra/exports   | 1 -
 src/lua/error.c | 9 +++++++++
 src/lua/init.c  | 4 ++++
 3 files changed, 13 insertions(+), 1 deletion(-)

diff --git a/extra/exports b/extra/exports
index 30dbb63ff..1e7a1a49f 100644
--- a/extra/exports
+++ b/extra/exports
@@ -2,7 +2,6 @@
 
 # Module API
 
-luaT_error
 box_txn
 box_txn_begin
 box_txn_commit
diff --git a/src/lua/error.c b/src/lua/error.c
index 18a990a88..e3e9c6c9a 100644
--- a/src/lua/error.c
+++ b/src/lua/error.c
@@ -124,3 +124,12 @@ tarantool_lua_error_init(struct lua_State *L)
 	CTID_CONST_STRUCT_ERROR_REF = luaL_ctypeid(L, "const struct error &");
 	assert(CTID_CONST_STRUCT_ERROR_REF != 0);
 }
+
+void **
+tarantool_lua_error_export_syms(void)
+{
+	static void *syms[] = {
+		(void *)luaT_error,
+	};
+	return syms;
+}
diff --git a/src/lua/init.c b/src/lua/init.c
index 6204961ba..daa685f57 100644
--- a/src/lua/init.c
+++ b/src/lua/init.c
@@ -737,6 +737,9 @@ tarantool_lua_buffer_export_syms(void);
 void **
 tarantool_lua_digest_export_syms(void);
 
+void **
+tarantool_lua_error_export_syms(void);
+
 void **
 tarantool_lua_msgpack_export_syms(void);
 
@@ -759,6 +762,7 @@ tarantool_lua_export_syms(void)
 		/* Submodules. */
 		(void *)tarantool_lua_buffer_export_syms,
 		(void *)tarantool_lua_digest_export_syms,
+		(void *)tarantool_lua_error_export_syms,
 		(void *)tarantool_lua_msgpack_export_syms,
 		(void *)tarantool_lua_socket_export_syms,
 		(void *)tarantool_lua_tnt_iconv_export_syms,
-- 
2.21.1 (Apple Git-122.3)



More information about the Tarantool-patches mailing list