Introduce the LuaCsLogger class and make everything use that instead
This commit is contained in:
@@ -18,10 +18,9 @@ namespace TestProject.LuaCs
|
||||
// same methods, otherwise we get script ownership exceptions.
|
||||
luaCs = luaCsFixture.LuaCs;
|
||||
|
||||
luaCs.MessageLogger = (prefix, o) =>
|
||||
LuaCsLogger.MessageLogger = (o) =>
|
||||
{
|
||||
o ??= "null";
|
||||
output?.WriteLine(prefix + o);
|
||||
output?.WriteLine($"{o}");
|
||||
};
|
||||
|
||||
UserData.RegisterType<TestValueType>();
|
||||
|
||||
@@ -15,7 +15,7 @@ namespace TestProject.LuaCs
|
||||
{
|
||||
public LuaCsFixture()
|
||||
{
|
||||
LuaCs.ExceptionHandler = (ex, _) =>
|
||||
LuaCsLogger.ExceptionHandler = (ex, _) =>
|
||||
{
|
||||
// Pretend we never caught the exception in the first place
|
||||
// (this allows us to preserve the stack trace)
|
||||
|
||||
Reference in New Issue
Block a user