When Parsing lambda expression, it evaluates the predicate and cannot be reused (e.g. from cache) with another parameter value.
See an example that demonstrates it.
var target = new Interpreter(InterpreterOptions.Default | InterpreterOptions.LambdaExpressions);
var list = new Parameter("list", new[] { 1, 2, 3 });
var value1 = new Parameter("value", 1);
var value2 = new Parameter("value", 2);
var expression = "list.Where(x => x > value)";
var lambda = target.Parse(expression, list, value1);
var result = lambda.Invoke(list, value2);
Assert.AreEqual(new[] { 3 }, result);
When Parsing lambda expression, it evaluates the predicate and cannot be reused (e.g. from cache) with another parameter value.
See an example that demonstrates it.