added custom context to be used in optimization evaluations that should expose all programmers issues, while allowing reporting errors to the error snooping entity. Fixes #875

This commit is contained in:
gnembon committed 2021-05-22 01:21:20 -03:00
1 parent deb4f78347
commit f21897fab1
4 files changed
+76 -10

No files matched your search

+6 -1
View File
@@ -105,7 +105,12 @@ public abstract class ScriptHost
public final Module main;
public Fluff.TriFunction<Expression, Tokenizer.Token, String, List<String>> errorSnooper = null;
@FunctionalInterface
public interface ErrorSnooper
{
List<String> apply(Expression expression, Tokenizer.Token token, String message);
}
public ErrorSnooper errorSnooper = null;
protected ScriptHost(Module code, boolean perUser, ScriptHost parent)
{