diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-08-16 14:58:02 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-08-16 14:58:02 -0300 |
commit | b96b0b5abbf40cbdbed7952bf35a5a27ddf75928 (patch) | |
tree | 5d9d5463cb7d3424833abab20dd87bce1f4b240f /lauxlib.h | |
parent | ca13be9af784b7288d3a07d9b5bccb329086e885 (diff) | |
download | lua-github-b96b0b5abbf40cbdbed7952bf35a5a27ddf75928.tar.gz |
Added macro 'luaL_pushfail'
The macro 'luaL_pushfail' documents all places in the standard libraries
that return nil to signal some kind of failure. It is defined as
'lua_pushnil'. The manual also got a notation (@fail) to document those
returns. The tests were changed to be agnostic regarding whether 'fail'
is 'nil' or 'false'.
Diffstat (limited to 'lauxlib.h')
-rw-r--r-- | lauxlib.h | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -153,6 +153,10 @@ LUALIB_API void (luaL_requiref) (lua_State *L, const char *modname, #define luaL_loadbuffer(L,s,sz,n) luaL_loadbufferx(L,s,sz,n,NULL) +/* push the value used to represent failure/error */ +#define luaL_pushfail(L) lua_pushnil(L) + + /* ** {====================================================== ** Generic Buffer manipulation |