private function statement() {
    switch ($this->currentType) {
      case T_CLOSE_TAG:
        // A close tag escapes into template mode.
        $node = new TemplateNode();
        $this->mustMatch(T_CLOSE_TAG, $node);
        $this->templateStatementList($node);
        if ($this->iterator->hasNext()) {
          $this->mustMatch(T_OPEN_TAG, $node, NULL, TRUE, TRUE);
        }
        return $node;
      case T_IF:
        return $this->_if();
      case T_WHILE:
        return $this->_while();
      case T_DO:
        return $this->doWhile();
      case T_FOR:
        return $this->_for();
      case T_SWITCH:
        return $this->_switch();
      case T_BREAK:
        return $this->_break();
      case T_CONTINUE:
        return $this->_continue();
      case T_RETURN:
        return $this->_return();
      case T_YIELD:
        $node = new YieldStatementNode();
        $node->addChild($this->_yield());
        $this->endStatement($node);
        return $node;
      case T_GLOBAL:
        return $this->_global();
      case T_ECHO:
        return $this->_echo();
      case T_UNSET:
        return $this->_unset();
      case T_FOREACH:
        return $this->_foreach();
      case T_DECLARE:
        return $this->_declare();
      case T_TRY:
        return $this->_try();
      case T_THROW:
        return $this->_throw();
      case T_GOTO:
        return $this->_goto();
      case '{':
        return $this->innerStatementBlock();
      case ';':
        $node = new BlankStatementNode();
        $this->endStatement($node);
        return $node;
      case T_STATIC:
        if ($this->isLookAhead(T_VARIABLE)) {
          return $this->staticVariableList();
        }
        else {
          return $this->exprStatement();
        }
      case T_STRING:
        if ($this->isLookAhead(':')) {
          $node = new GotoLabelNode();
          $this->mustMatch(T_STRING, $node, 'label');
          $this->mustMatch(':', $node, NULL, TRUE, TRUE);
          return $node;
        }
        else {
          return $this->exprStatement();
        }
      default:
        return $this->exprStatement();
    }
  }