aboutsummaryrefslogtreecommitdiff
path: root/lstate.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2019-03-14 15:30:54 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2019-03-14 15:30:54 -0300
commitb56d4e570a60a8e84df8288c3122eb5bb5c20af6 (patch)
treed5597a7865712fc407adbb41fe0749e728617ca7 /lstate.c
parent9eca305e75010e30342486a4139846faf1b3eccb (diff)
downloadlua-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.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lstate.c b/lstate.c
index 6c35ea1a..f5579a66 100644
--- a/lstate.c
+++ b/lstate.c
@@ -411,10 +411,10 @@ LUA_API void lua_close (lua_State *L) {
411} 411}
412 412
413 413
414void luaE_warning (lua_State *L, const char *msg) { 414void 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