diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-03-14 15:30:54 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-03-14 15:30:54 -0300 |
commit | b56d4e570a60a8e84df8288c3122eb5bb5c20af6 (patch) | |
tree | d5597a7865712fc407adbb41fe0749e728617ca7 /lstate.c | |
parent | 9eca305e75010e30342486a4139846faf1b3eccb (diff) | |
download | lua-b56d4e570a60a8e84df8288c3122eb5bb5c20af6.tar.gz lua-b56d4e570a60a8e84df8288c3122eb5bb5c20af6.tar.bz2 lua-b56d4e570a60a8e84df8288c3122eb5bb5c20af6.zip |
Changes in the warning system
- The warning functions get an extra parameter that tells whether
message is to be continued (instead of using end-of-lines as a signal).
- The user data for the warning function is a regular value, instead
of a writable slot inside the Lua state.
Diffstat (limited to 'lstate.c')
-rw-r--r-- | lstate.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -411,10 +411,10 @@ LUA_API void lua_close (lua_State *L) { | |||
411 | } | 411 | } |
412 | 412 | ||
413 | 413 | ||
414 | void luaE_warning (lua_State *L, const char *msg) { | 414 | void luaE_warning (lua_State *L, const char *msg, int tocont) { |
415 | lua_WarnFunction wf = G(L)->warnf; | 415 | lua_WarnFunction wf = G(L)->warnf; |
416 | if (wf != NULL) | 416 | if (wf != NULL) |
417 | wf(&G(L)->ud_warn, msg); | 417 | wf(G(L)->ud_warn, msg, tocont); |
418 | } | 418 | } |
419 | 419 | ||
420 | 420 | ||