diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-10-29 14:12:30 -0200 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-10-29 14:12:30 -0200 |
| commit | 05afee0f50f64b64dbb4c0614ccf737ffdc06ab6 (patch) | |
| tree | 76ddccce1152f3bb51ef80b801f6df4bf47c1525 /lua.c | |
| parent | 351a446ec55d0e4a7520791cc4b6ff6097739e18 (diff) | |
| download | lua-github-05afee0f50f64b64dbb4c0614ccf737ffdc06ab6.tar.gz | |
definitions for 'luai_writestring'/'luai_writeline'/'luai_writestringerror'
moved to 'lauxlib.h' (they do not need to be stable or configurable) +
prefixes changed from 'luai_' to 'lua_' (they are not part of the core)
Diffstat (limited to 'lua.c')
| -rw-r--r-- | lua.c | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -1,5 +1,5 @@ /* -** $Id: lua.c,v 1.216 2014/10/20 18:19:26 roberto Exp roberto $ +** $Id: lua.c,v 1.217 2014/10/20 22:21:05 roberto Exp roberto $ ** Lua stand-alone interpreter ** See Copyright Notice in lua.h */ @@ -126,12 +126,12 @@ static void laction (int i) { static void print_usage (const char *badoption) { - luai_writestringerror("%s: ", progname); + lua_writestringerror("%s: ", progname); if (badoption[1] == 'e' || badoption[1] == 'l') - luai_writestringerror("'%s' needs argument\n", badoption); + lua_writestringerror("'%s' needs argument\n", badoption); else - luai_writestringerror("unrecognized option '%s'\n", badoption); - luai_writestringerror( + lua_writestringerror("unrecognized option '%s'\n", badoption); + lua_writestringerror( "usage: %s [options] [script [args]]\n" "Available options are:\n" " -e stat execute string 'stat'\n" @@ -151,8 +151,8 @@ static void print_usage (const char *badoption) { ** (if present) */ static void l_message (const char *pname, const char *msg) { - if (pname) luai_writestringerror("%s: ", pname); - luai_writestringerror("%s\n", msg); + if (pname) lua_writestringerror("%s: ", pname); + lua_writestringerror("%s\n", msg); } @@ -208,8 +208,8 @@ static int docall (lua_State *L, int narg, int nres) { static void print_version (void) { - luai_writestring(LUA_COPYRIGHT, strlen(LUA_COPYRIGHT)); - luai_writeline(); + lua_writestring(LUA_COPYRIGHT, strlen(LUA_COPYRIGHT)); + lua_writeline(); } @@ -410,7 +410,7 @@ static void doREPL (lua_State *L) { else report(L, status); } lua_settop(L, 0); /* clear stack */ - luai_writeline(); + lua_writeline(); progname = oldprogname; } |
