示例#1
0
        public override void Evaluate(Runtime Runtime)
        {
            Scope Outer = new Scope(new ScopeInfo());

            Runtime.Stack.Push(Outer);

            Initial.Evaluate(Runtime);

            Condition.Evaluate(Runtime);
            bool Current = (bool)Runtime.Register;

            while (Current == true)
            {
                Runtime.RunScope(Body);

                Iteration.Evaluate(Runtime);
                Condition.Evaluate(Runtime);
                Current = (bool)Runtime.Register;
            }

            Runtime.Stack.Pop();
        }
示例#2
0
 public static Evaluator Assert(int current)
 {
     return(new Evaluator(Initial.Evaluate(current), new List <string>()));
 }