[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: lua_writestringerror is used for warning messages AND panic errors?
- From: bil til <biltil52@...>
- Date: Fri, 25 Nov 2022 21:43:25 +0100
... see lauxlib.h/lauxlib.c
Is this really intended?
Is there any "recommended way" to use separate outputs for errors and
for warnings?
(usually I catch all my errors from the result of lua_resume, if
error-flag is returned there... . but if any lua_error happens out of
resume, then panic will be invoked. In this case I would stop the
controller and run in some "bios/emergency program handling", where I
then can send the error info nicely to the user... . But if a warning
message is shown (e. g. by invoking warn function of Lua somewhere in
the Lua code), this would be a bit "overdriven" - I would prefer to
handle such "regular warnings" differently... .)