diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2018-08-16 14:38:05 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2018-08-16 14:38:05 -0300 |
commit | faaf7e481fbadc2ef520a96b638dd910f3c9ff14 (patch) | |
tree | 3bb522291e367a81ac2edbaa43fff02ef6f221c8 /lua.c | |
parent | 3d838f635cc81ec3332f9a904992db1c6d8a46ad (diff) | |
download | lua-faaf7e481fbadc2ef520a96b638dd910f3c9ff14.tar.gz lua-faaf7e481fbadc2ef520a96b638dd910f3c9ff14.tar.bz2 lua-faaf7e481fbadc2ef520a96b638dd910f3c9ff14.zip |
Removed use of 'rl_inhibit_completion' in 'lua.c'
Some old systems (e.g., Mac OS X 10.4) do not define
'rl_inhibit_completion', even when line history is available.
Anyway, the user can configure this option externally, using '~/.inputrc'.
Diffstat (limited to 'lua.c')
-rw-r--r-- | lua.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lua.c,v 1.234 2018/03/06 20:30:17 roberto Exp roberto $ | 2 | ** $Id: lua.c $ |
3 | ** Lua stand-alone interpreter | 3 | ** Lua stand-alone interpreter |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -383,8 +383,7 @@ static int handle_luainit (lua_State *L) { | |||
383 | 383 | ||
384 | #include <readline/readline.h> | 384 | #include <readline/readline.h> |
385 | #include <readline/history.h> | 385 | #include <readline/history.h> |
386 | #define lua_initreadline(L) \ | 386 | #define lua_initreadline(L) ((void)L, rl_readline_name="lua") |
387 | ((void)L, rl_readline_name="lua", rl_inhibit_completion=1) | ||
388 | #define lua_readline(L,b,p) ((void)L, ((b)=readline(p)) != NULL) | 387 | #define lua_readline(L,b,p) ((void)L, ((b)=readline(p)) != NULL) |
389 | #define lua_saveline(L,line) ((void)L, add_history(line)) | 388 | #define lua_saveline(L,line) ((void)L, add_history(line)) |
390 | #define lua_freeline(L,b) ((void)L, free(b)) | 389 | #define lua_freeline(L,b) ((void)L, free(b)) |