aboutsummaryrefslogtreecommitdiff
path: root/lua.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2025-06-26 11:45:42 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2025-06-26 11:45:42 -0300
commitf6c627af20e48ae96bd17f4392ca74ce0ae90f36 (patch)
tree1361f8e40cd0dde811728786594a18c235f3d8a8 /lua.c
parent270a58c0629dea1a376f05433e8df383756173a8 (diff)
downloadlua-f6c627af20e48ae96bd17f4392ca74ce0ae90f36.tar.gz
lua-f6c627af20e48ae96bd17f4392ca74ce0ae90f36.tar.bz2
lua-f6c627af20e48ae96bd17f4392ca74ce0ae90f36.zip
Cast added to 'add_history'
MacOS defines 'add_history' with a "wrong" type (it returns 'int' instead of 'void').
Diffstat (limited to 'lua.c')
-rw-r--r--lua.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lua.c b/lua.c
index 3fe9b7da..a90bf29b 100644
--- a/lua.c
+++ b/lua.c
@@ -488,8 +488,8 @@ static void lua_freeline (char *line) {
488static void lua_initreadline(lua_State *L) { 488static void lua_initreadline(lua_State *L) {
489 UNUSED(L); 489 UNUSED(L);
490 rl_readline_name = "lua"; 490 rl_readline_name = "lua";
491 l_readline = readline; 491 l_readline = cast(l_readlineT, readline);
492 l_addhist = add_history; 492 l_addhist = cast(l_addhistT, add_history);
493} 493}
494 494
495#elif defined(LUA_USE_DLOPEN) && defined(LUA_READLINELIB) /* }{ */ 495#elif defined(LUA_USE_DLOPEN) && defined(LUA_READLINELIB) /* }{ */