Пример #1
0
 public bool Run(Environment env, Scope scope)
 {
     int size = code.Count();
     while (scope.line < size)
     {
         var r = code[scope.line++].Execute(env);
         if (r == ReturnCode.None)
             continue;
         if (r == ReturnCode.Yield)
             return false;
         return true;
     }
     env.endScope();
     return true;
 }
Пример #2
0
 public void AddScope(Scope s)
 {
     s.Set(scope);
     scope = s;
 }
Пример #3
0
 public void endScope()
 {
     scope = scope.End();
 }
Пример #4
0
 public void Set(Scope s)
 {
     next = s;
 }