public function rewriteChildren()

in codegen/syntax/AnonymousClass.hack [178:232]


  public function rewriteChildren<Tret as ?Node>(
    (function(Node, vec<Node>): Tret) $rewriter,
    vec<Node> $parents = vec[],
  ): this {
    $parents[] = $this;
    $class_keyword = $this->_class_keyword === null
      ? null
      : $rewriter($this->_class_keyword, $parents);
    $left_paren = $this->_left_paren === null
      ? null
      : $rewriter($this->_left_paren, $parents);
    $argument_list = $this->_argument_list === null
      ? null
      : $rewriter($this->_argument_list, $parents);
    $right_paren = $this->_right_paren === null
      ? null
      : $rewriter($this->_right_paren, $parents);
    $extends_keyword = $this->_extends_keyword === null
      ? null
      : $rewriter($this->_extends_keyword, $parents);
    $extends_list = $this->_extends_list === null
      ? null
      : $rewriter($this->_extends_list, $parents);
    $implements_keyword = $this->_implements_keyword === null
      ? null
      : $rewriter($this->_implements_keyword, $parents);
    $implements_list = $this->_implements_list === null
      ? null
      : $rewriter($this->_implements_list, $parents);
    $body = $this->_body === null ? null : $rewriter($this->_body, $parents);
    if (
      $class_keyword === $this->_class_keyword &&
      $left_paren === $this->_left_paren &&
      $argument_list === $this->_argument_list &&
      $right_paren === $this->_right_paren &&
      $extends_keyword === $this->_extends_keyword &&
      $extends_list === $this->_extends_list &&
      $implements_keyword === $this->_implements_keyword &&
      $implements_list === $this->_implements_list &&
      $body === $this->_body
    ) {
      return $this;
    }
    return new static(
      $class_keyword as ?Node,
      $left_paren as ?Node,
      $argument_list as ?Node,
      $right_paren as ?Node,
      $extends_keyword as ?Node,
      $extends_list as ?Node,
      $implements_keyword as ?Node,
      $implements_list as ?Node,
      $body as ?Node,
    );
  }