Пример #1
0
 public function execute(array $arguments, RussellInterpreter\Interpreter $core)
 {
     $value = $arguments[0];
     if (is_array($value)) {
         $name = $value['name'];
         $value = $core->getVariable($name, 0);
         $value--;
         $core->setVariable($name, $value);
     } else {
         if (!is_numeric($arguments[0])) {
             $value = $core->calculation($arguments[0]);
         }
         $value--;
     }
     return $value;
 }
Пример #2
0
 public function execute(array $arguments, RussellInterpreter\Interpreter $core)
 {
     //        $name = trim($arguments[0], '\'"');
     $core->setVariable($arguments[0], $arguments[1]);
 }
Пример #3
0
 public function init(RussellInterpreter\Interpreter $core)
 {
     $core->setVariable('false', false);
 }
Пример #4
0
 public function init(RussellInterpreter\Interpreter $core)
 {
     $core->setVariable('true', true);
 }