Explorar o código

Fix for bug found during running unit tests

auz34 %!s(int64=11) %!d(string=hai) anos
pai
achega
5e98352a67
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      Jint/Runtime/ExpressionIntepreter.cs

+ 1 - 1
Jint/Runtime/ExpressionIntepreter.cs

@@ -797,7 +797,7 @@ namespace Jint.Runtime
             var func = _engine.GetValue(callee);
             
             var r = callee as Reference;
-            var stackItem = new Tuple<CallExpression, JsValue, string>(callExpression, func, r.GetReferencedName());
+            var stackItem = new Tuple<CallExpression, JsValue, string>(callExpression, func, r != null ? r.GetReferencedName() : "anonymous function");
 
             var recursionDepth = _engine.CallStack.Count(ce => ce.Item1 == callExpression || ce.Item2 == func);