Surface ICodedFunction exceptions: set interpreter message via ProduceOutput in ExecuteFunction
This commit is contained in:
parent
9b74c03a9d
commit
808d4ca420
1 changed files with 3 additions and 1 deletions
|
@ -186,8 +186,10 @@ namespace CSMic
|
|||
{
|
||||
return fn.Execute(args);
|
||||
}
|
||||
catch
|
||||
catch (Exception ex)
|
||||
{
|
||||
// Surface function errors to the interpreter's message channel
|
||||
ProduceOutput(0m, ex.Message);
|
||||
return new FunctionValue(FunctionValueType.None, null);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue