Beispiel #1
0
        private static InterpretedFrame?EnterCurrentFrame(InterpretedFrame frame)
        {
            var currentFrame = _currentFrame;

            _currentFrame = frame;
            return(currentFrame);
        }
Beispiel #2
0
        public object?RunVoid(params object?[] arguments)
        {
            InterpretedFrame frame = MakeFrame();

            for (int i = 0; i < arguments.Length; i++)
            {
                frame.Data[i] = arguments[i];
            }
            InterpretedFrame?currentFrame = frame.Enter();

            try
            {
                _interpreter.Run(frame);
            }
            finally
            {
                for (int i = 0; i < arguments.Length; i++)
                {
                    arguments[i] = frame.Data[i];
                }

                frame.Leave(currentFrame);
            }
            return(null);
        }
        internal InterpretedFrame?Enter()
        {
            InterpretedFrame?currentFrame = s_currentFrame;

            s_currentFrame = this;
            return(_parent = currentFrame);
        }
Beispiel #4
0
        internal InterpretedFrame?Enter()
        {
            var currentFrame = _currentFrame;

            _currentFrame = this;
            return(Parent = currentFrame);
        }
        public IEnumerable <InterpretedFrameInfo> GetStackTraceDebugInfo()
        {
            InterpretedFrame?frame = this;

            do
            {
                yield return(new InterpretedFrameInfo(frame.Name, frame.GetDebugInfo(frame.InstructionIndex)));

                frame = frame.Parent;
            } while (frame != null);
        }
 internal static void Leave(InterpretedFrame?prevFrame)
 {
     s_currentFrame = prevFrame;
 }
Beispiel #7
0
 private static void LeaveCurrentFrame(InterpretedFrame?prevFrame)
 {
     _currentFrame = prevFrame;
 }
Beispiel #8
0
 internal void Leave(InterpretedFrame?prevFrame)
 {
     LeaveCurrentFrame(prevFrame);
 }
Beispiel #9
0
 internal void Leave(InterpretedFrame?prevFrame)
 {
     _currentFrame = prevFrame;
 }