Mercurial > vim
comparison src/if_lua.c @ 21012:380923b96878 v8.2.1057
patch 8.2.1057: cannot build with dynamic Lua
Commit: https://github.com/vim/vim/commit/1e4c7d0ed272201fa3a7cf34a462abb139170759
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Jun 25 20:56:42 2020 +0200
patch 8.2.1057: cannot build with dynamic Lua
Problem: Cannot build with dynamic Lua.
Solution: Add dll variables.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 25 Jun 2020 21:00:18 +0200 |
parents | ae185f35e256 |
children | 08e284594211 |
comparison
equal
deleted
inserted
replaced
21011:79651004e6df | 21012:380923b96878 |
---|---|
129 #define luaL_newstate dll_luaL_newstate | 129 #define luaL_newstate dll_luaL_newstate |
130 #define luaL_buffinit dll_luaL_buffinit | 130 #define luaL_buffinit dll_luaL_buffinit |
131 #define luaL_addlstring dll_luaL_addlstring | 131 #define luaL_addlstring dll_luaL_addlstring |
132 #define luaL_pushresult dll_luaL_pushresult | 132 #define luaL_pushresult dll_luaL_pushresult |
133 #define luaL_loadstring dll_luaL_loadstring | 133 #define luaL_loadstring dll_luaL_loadstring |
134 #define luaL_ref dll_luaL_ref | |
135 #define luaL_unref dll_luaL_unref | |
134 // lua | 136 // lua |
135 #if LUA_VERSION_NUM <= 501 | 137 #if LUA_VERSION_NUM <= 501 |
136 #define lua_tonumber dll_lua_tonumber | 138 #define lua_tonumber dll_lua_tonumber |
137 #define lua_tointeger dll_lua_tointeger | 139 #define lua_tointeger dll_lua_tointeger |
138 #define lua_call dll_lua_call | 140 #define lua_call dll_lua_call |
224 lua_State *(*dll_luaL_newstate) (void); | 226 lua_State *(*dll_luaL_newstate) (void); |
225 void (*dll_luaL_buffinit) (lua_State *L, luaL_Buffer *B); | 227 void (*dll_luaL_buffinit) (lua_State *L, luaL_Buffer *B); |
226 void (*dll_luaL_addlstring) (luaL_Buffer *B, const char *s, size_t l); | 228 void (*dll_luaL_addlstring) (luaL_Buffer *B, const char *s, size_t l); |
227 void (*dll_luaL_pushresult) (luaL_Buffer *B); | 229 void (*dll_luaL_pushresult) (luaL_Buffer *B); |
228 int (*dll_luaL_loadstring) (lua_State *L, const char *s); | 230 int (*dll_luaL_loadstring) (lua_State *L, const char *s); |
231 int (*dll_luaL_ref) (lua_State *L, int idx); | |
232 #if LUA_VERSION_NUM <= 502 | |
233 void (*dll_luaL_unref) (lua_State *L, int idx, int n); | |
234 #else | |
235 void (*dll_luaL_unref) (lua_State *L, int idx, lua_Integer n); | |
236 #endif | |
229 // lua | 237 // lua |
230 #if LUA_VERSION_NUM <= 501 | 238 #if LUA_VERSION_NUM <= 501 |
231 lua_Number (*dll_lua_tonumber) (lua_State *L, int idx); | 239 lua_Number (*dll_lua_tonumber) (lua_State *L, int idx); |
232 lua_Integer (*dll_lua_tointeger) (lua_State *L, int idx); | 240 lua_Integer (*dll_lua_tointeger) (lua_State *L, int idx); |
233 void (*dll_lua_call) (lua_State *L, int nargs, int nresults); | 241 void (*dll_lua_call) (lua_State *L, int nargs, int nresults); |
337 {"luaL_newstate", (luaV_function) &dll_luaL_newstate}, | 345 {"luaL_newstate", (luaV_function) &dll_luaL_newstate}, |
338 {"luaL_buffinit", (luaV_function) &dll_luaL_buffinit}, | 346 {"luaL_buffinit", (luaV_function) &dll_luaL_buffinit}, |
339 {"luaL_addlstring", (luaV_function) &dll_luaL_addlstring}, | 347 {"luaL_addlstring", (luaV_function) &dll_luaL_addlstring}, |
340 {"luaL_pushresult", (luaV_function) &dll_luaL_pushresult}, | 348 {"luaL_pushresult", (luaV_function) &dll_luaL_pushresult}, |
341 {"luaL_loadstring", (luaV_function) &dll_luaL_loadstring}, | 349 {"luaL_loadstring", (luaV_function) &dll_luaL_loadstring}, |
350 {"luaL_ref", (luaV_function) &dll_luaL_ref}, | |
351 {"luaL_unref", (luaV_function) &dll_luaL_unref}, | |
342 // lua | 352 // lua |
343 #if LUA_VERSION_NUM <= 501 | 353 #if LUA_VERSION_NUM <= 501 |
344 {"lua_tonumber", (luaV_function) &dll_lua_tonumber}, | 354 {"lua_tonumber", (luaV_function) &dll_lua_tonumber}, |
345 {"lua_tointeger", (luaV_function) &dll_lua_tointeger}, | 355 {"lua_tointeger", (luaV_function) &dll_lua_tointeger}, |
346 {"lua_call", (luaV_function) &dll_lua_call}, | 356 {"lua_call", (luaV_function) &dll_lua_call}, |