Skip to content

Commit c7fc80a

Browse files
author
Sébastien Geiser
committed
Refactoring
1 parent fd126c2 commit c7fc80a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

CodingSeb.ExpressionEvaluator/ExpressionEvaluator.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1919,11 +1919,11 @@ protected virtual bool EvaluateVarOrFunc(string expression, Stack<object> stack,
19191919
}
19201920
else if (Variables.TryGetValue(varFuncName, out object o) && o is InternalDelegate lambdaExpression)
19211921
{
1922-
stack.Push(lambdaExpression.Invoke(funcArgs.ConvertAll(e => Evaluate(e)).ToArray()));
1922+
stack.Push(lambdaExpression.Invoke(funcArgs.ConvertAll(Evaluate).ToArray()));
19231923
}
19241924
else if (Variables.TryGetValue(varFuncName, out o) && o is Delegate delegateVar)
19251925
{
1926-
stack.Push(delegateVar.DynamicInvoke(funcArgs.ConvertAll(e => Evaluate(e)).ToArray()));
1926+
stack.Push(delegateVar.DynamicInvoke(funcArgs.ConvertAll(Evaluate).ToArray()));
19271927
}
19281928
else
19291929
{

0 commit comments

Comments
 (0)