//! Generated file, do not edit by hand, see `xtask/codegen`

#![allow(dead_code)]
#![allow(unused)]
use crate::{
    JsLanguage as Language, JsSyntaxElement as SyntaxElement,
    JsSyntaxElementChildren as SyntaxElementChildren,
    JsSyntaxKind::{self as SyntaxKind, *},
    JsSyntaxList as SyntaxList, JsSyntaxNode as SyntaxNode, JsSyntaxToken as SyntaxToken,
    macros::map_syntax_node,
};
use biome_rowan::{
    AstNode, AstNodeList, AstNodeListIterator, AstNodeSlotMap, AstSeparatedList,
    AstSeparatedListNodesIterator, RawSyntaxKind, SyntaxKindSet, SyntaxResult, support,
};
use serde::ser::SerializeSeq;
use serde::{Serialize, Serializer};
use std::fmt::{Debug, Formatter};
#[doc = r" Sentinel value indicating a missing element in a dynamic node, where"]
#[doc = r" the slots are not statically known."]
pub(crate) const SLOT_MAP_EMPTY_VALUE: u8 = u8::MAX;
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsAccessorModifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsAccessorModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsAccessorModifierFields {
        JsAccessorModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsAccessorModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsAccessorModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayAssignmentPattern {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayAssignmentPattern {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayAssignmentPatternFields {
        JsArrayAssignmentPatternFields {
            l_brack_token: self.l_brack_token(),
            elements: self.elements(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn elements(&self) -> JsArrayAssignmentPatternElementList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsArrayAssignmentPattern {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayAssignmentPatternFields {
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub elements: JsArrayAssignmentPatternElementList,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayAssignmentPatternElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayAssignmentPatternElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayAssignmentPatternElementFields {
        JsArrayAssignmentPatternElementFields {
            pattern: self.pattern(),
            init: self.init(),
        }
    }
    pub fn pattern(&self) -> SyntaxResult<AnyJsAssignmentPattern> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn init(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for JsArrayAssignmentPatternElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayAssignmentPatternElementFields {
    pub pattern: SyntaxResult<AnyJsAssignmentPattern>,
    pub init: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayAssignmentPatternRestElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayAssignmentPatternRestElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayAssignmentPatternRestElementFields {
        JsArrayAssignmentPatternRestElementFields {
            dotdotdot_token: self.dotdotdot_token(),
            pattern: self.pattern(),
        }
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn pattern(&self) -> SyntaxResult<AnyJsAssignmentPattern> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsArrayAssignmentPatternRestElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayAssignmentPatternRestElementFields {
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub pattern: SyntaxResult<AnyJsAssignmentPattern>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayBindingPattern {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayBindingPattern {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayBindingPatternFields {
        JsArrayBindingPatternFields {
            l_brack_token: self.l_brack_token(),
            elements: self.elements(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn elements(&self) -> JsArrayBindingPatternElementList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsArrayBindingPattern {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayBindingPatternFields {
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub elements: JsArrayBindingPatternElementList,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayBindingPatternElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayBindingPatternElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayBindingPatternElementFields {
        JsArrayBindingPatternElementFields {
            pattern: self.pattern(),
            init: self.init(),
        }
    }
    pub fn pattern(&self) -> SyntaxResult<AnyJsBindingPattern> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn init(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for JsArrayBindingPatternElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayBindingPatternElementFields {
    pub pattern: SyntaxResult<AnyJsBindingPattern>,
    pub init: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayBindingPatternRestElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayBindingPatternRestElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayBindingPatternRestElementFields {
        JsArrayBindingPatternRestElementFields {
            dotdotdot_token: self.dotdotdot_token(),
            pattern: self.pattern(),
        }
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn pattern(&self) -> SyntaxResult<AnyJsBindingPattern> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsArrayBindingPatternRestElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayBindingPatternRestElementFields {
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub pattern: SyntaxResult<AnyJsBindingPattern>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayExpressionFields {
        JsArrayExpressionFields {
            l_brack_token: self.l_brack_token(),
            elements: self.elements(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn elements(&self) -> JsArrayElementList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsArrayExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayExpressionFields {
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub elements: JsArrayElementList,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrayHole {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrayHole {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrayHoleFields {
        JsArrayHoleFields {}
    }
}
impl Serialize for JsArrayHole {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrayHoleFields {}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsArrowFunctionExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsArrowFunctionExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsArrowFunctionExpressionFields {
        JsArrowFunctionExpressionFields {
            async_token: self.async_token(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            fat_arrow_token: self.fat_arrow_token(),
            body: self.body(),
        }
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 1usize)
    }
    pub fn parameters(&self) -> SyntaxResult<AnyJsArrowFunctionParameters> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 3usize)
    }
    pub fn fat_arrow_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsFunctionBody> {
        support::required_node(&self.syntax, 5usize)
    }
}
impl Serialize for JsArrowFunctionExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsArrowFunctionExpressionFields {
    pub async_token: Option<SyntaxToken>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<AnyJsArrowFunctionParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub fat_arrow_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsAssignmentExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsAssignmentExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsAssignmentExpressionFields {
        JsAssignmentExpressionFields {
            left: self.left(),
            operator_token: self.operator_token(),
            right: self.right(),
        }
    }
    pub fn left(&self) -> SyntaxResult<AnyJsAssignmentPattern> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn right(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsAssignmentExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsAssignmentExpressionFields {
    pub left: SyntaxResult<AnyJsAssignmentPattern>,
    pub operator_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsAwaitExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsAwaitExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsAwaitExpressionFields {
        JsAwaitExpressionFields {
            await_token: self.await_token(),
            argument: self.argument(),
        }
    }
    pub fn await_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn argument(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsAwaitExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsAwaitExpressionFields {
    pub await_token: SyntaxResult<SyntaxToken>,
    pub argument: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsBigintLiteralExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsBigintLiteralExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsBigintLiteralExpressionFields {
        JsBigintLiteralExpressionFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsBigintLiteralExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsBigintLiteralExpressionFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsBinaryExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsBinaryExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsBinaryExpressionFields {
        JsBinaryExpressionFields {
            left: self.left(),
            operator_token: self.operator_token(),
            right: self.right(),
        }
    }
    pub fn left(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn right(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsBinaryExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsBinaryExpressionFields {
    pub left: SyntaxResult<AnyJsExpression>,
    pub operator_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsBlockStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsBlockStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsBlockStatementFields {
        JsBlockStatementFields {
            l_curly_token: self.l_curly_token(),
            statements: self.statements(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn statements(&self) -> JsStatementList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsBlockStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsBlockStatementFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub statements: JsStatementList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsBooleanLiteralExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsBooleanLiteralExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsBooleanLiteralExpressionFields {
        JsBooleanLiteralExpressionFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsBooleanLiteralExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsBooleanLiteralExpressionFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsBreakStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsBreakStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsBreakStatementFields {
        JsBreakStatementFields {
            break_token: self.break_token(),
            label: self.label(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn break_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn label(&self) -> Option<JsLabel> {
        support::node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for JsBreakStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsBreakStatementFields {
    pub break_token: SyntaxResult<SyntaxToken>,
    pub label: Option<JsLabel>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsCallArguments {
    pub(crate) syntax: SyntaxNode,
}
impl JsCallArguments {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsCallArgumentsFields {
        JsCallArgumentsFields {
            l_paren_token: self.l_paren_token(),
            args: self.args(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn args(&self) -> JsCallArgumentList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsCallArguments {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsCallArgumentsFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub args: JsCallArgumentList,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsCallExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsCallExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsCallExpressionFields {
        JsCallExpressionFields {
            callee: self.callee(),
            optional_chain_token: self.optional_chain_token(),
            type_arguments: self.type_arguments(),
            arguments: self.arguments(),
        }
    }
    pub fn callee(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn optional_chain_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 2usize)
    }
    pub fn arguments(&self) -> SyntaxResult<JsCallArguments> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for JsCallExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsCallExpressionFields {
    pub callee: SyntaxResult<AnyJsExpression>,
    pub optional_chain_token: Option<SyntaxToken>,
    pub type_arguments: Option<TsTypeArguments>,
    pub arguments: SyntaxResult<JsCallArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsCaseClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsCaseClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsCaseClauseFields {
        JsCaseClauseFields {
            case_token: self.case_token(),
            test: self.test(),
            colon_token: self.colon_token(),
            consequent: self.consequent(),
        }
    }
    pub fn case_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn test(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn consequent(&self) -> JsStatementList {
        support::list(&self.syntax, 3usize)
    }
}
impl Serialize for JsCaseClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsCaseClauseFields {
    pub case_token: SyntaxResult<SyntaxToken>,
    pub test: SyntaxResult<AnyJsExpression>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub consequent: JsStatementList,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsCatchClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsCatchClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsCatchClauseFields {
        JsCatchClauseFields {
            catch_token: self.catch_token(),
            declaration: self.declaration(),
            body: self.body(),
        }
    }
    pub fn catch_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn declaration(&self) -> Option<JsCatchDeclaration> {
        support::node(&self.syntax, 1usize)
    }
    pub fn body(&self) -> SyntaxResult<JsBlockStatement> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsCatchClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsCatchClauseFields {
    pub catch_token: SyntaxResult<SyntaxToken>,
    pub declaration: Option<JsCatchDeclaration>,
    pub body: SyntaxResult<JsBlockStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsCatchDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl JsCatchDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsCatchDeclarationFields {
        JsCatchDeclarationFields {
            l_paren_token: self.l_paren_token(),
            binding: self.binding(),
            type_annotation: self.type_annotation(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn binding(&self) -> SyntaxResult<AnyJsBindingPattern> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsCatchDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsCatchDeclarationFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub binding: SyntaxResult<AnyJsBindingPattern>,
    pub type_annotation: Option<TsTypeAnnotation>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsClassDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl JsClassDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsClassDeclarationFields {
        JsClassDeclarationFields {
            decorators: self.decorators(),
            abstract_token: self.abstract_token(),
            class_token: self.class_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            extends_clause: self.extends_clause(),
            implements_clause: self.implements_clause(),
            l_curly_token: self.l_curly_token(),
            members: self.members(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn decorators(&self) -> JsDecoratorList {
        support::list(&self.syntax, 0usize)
    }
    pub fn abstract_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn class_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn id(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 4usize)
    }
    pub fn extends_clause(&self) -> Option<JsExtendsClause> {
        support::node(&self.syntax, 5usize)
    }
    pub fn implements_clause(&self) -> Option<TsImplementsClause> {
        support::node(&self.syntax, 6usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 7usize)
    }
    pub fn members(&self) -> JsClassMemberList {
        support::list(&self.syntax, 8usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 9usize)
    }
}
impl Serialize for JsClassDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsClassDeclarationFields {
    pub decorators: JsDecoratorList,
    pub abstract_token: Option<SyntaxToken>,
    pub class_token: SyntaxResult<SyntaxToken>,
    pub id: SyntaxResult<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub extends_clause: Option<JsExtendsClause>,
    pub implements_clause: Option<TsImplementsClause>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub members: JsClassMemberList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsClassExportDefaultDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl JsClassExportDefaultDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsClassExportDefaultDeclarationFields {
        JsClassExportDefaultDeclarationFields {
            decorators: self.decorators(),
            abstract_token: self.abstract_token(),
            class_token: self.class_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            extends_clause: self.extends_clause(),
            implements_clause: self.implements_clause(),
            l_curly_token: self.l_curly_token(),
            members: self.members(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn decorators(&self) -> JsDecoratorList {
        support::list(&self.syntax, 0usize)
    }
    pub fn abstract_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn class_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn id(&self) -> Option<AnyJsBinding> {
        support::node(&self.syntax, 3usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 4usize)
    }
    pub fn extends_clause(&self) -> Option<JsExtendsClause> {
        support::node(&self.syntax, 5usize)
    }
    pub fn implements_clause(&self) -> Option<TsImplementsClause> {
        support::node(&self.syntax, 6usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 7usize)
    }
    pub fn members(&self) -> JsClassMemberList {
        support::list(&self.syntax, 8usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 9usize)
    }
}
impl Serialize for JsClassExportDefaultDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsClassExportDefaultDeclarationFields {
    pub decorators: JsDecoratorList,
    pub abstract_token: Option<SyntaxToken>,
    pub class_token: SyntaxResult<SyntaxToken>,
    pub id: Option<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub extends_clause: Option<JsExtendsClause>,
    pub implements_clause: Option<TsImplementsClause>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub members: JsClassMemberList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsClassExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsClassExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsClassExpressionFields {
        JsClassExpressionFields {
            decorators: self.decorators(),
            class_token: self.class_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            extends_clause: self.extends_clause(),
            implements_clause: self.implements_clause(),
            l_curly_token: self.l_curly_token(),
            members: self.members(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn decorators(&self) -> JsDecoratorList {
        support::list(&self.syntax, 0usize)
    }
    pub fn class_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn id(&self) -> Option<AnyJsBinding> {
        support::node(&self.syntax, 2usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 3usize)
    }
    pub fn extends_clause(&self) -> Option<JsExtendsClause> {
        support::node(&self.syntax, 4usize)
    }
    pub fn implements_clause(&self) -> Option<TsImplementsClause> {
        support::node(&self.syntax, 5usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 6usize)
    }
    pub fn members(&self) -> JsClassMemberList {
        support::list(&self.syntax, 7usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 8usize)
    }
}
impl Serialize for JsClassExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsClassExpressionFields {
    pub decorators: JsDecoratorList,
    pub class_token: SyntaxResult<SyntaxToken>,
    pub id: Option<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub extends_clause: Option<JsExtendsClause>,
    pub implements_clause: Option<TsImplementsClause>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub members: JsClassMemberList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsComputedMemberAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl JsComputedMemberAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsComputedMemberAssignmentFields {
        JsComputedMemberAssignmentFields {
            object: self.object(),
            l_brack_token: self.l_brack_token(),
            member: self.member(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn object(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn member(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsComputedMemberAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsComputedMemberAssignmentFields {
    pub object: SyntaxResult<AnyJsExpression>,
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub member: SyntaxResult<AnyJsExpression>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsComputedMemberExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsComputedMemberExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsComputedMemberExpressionFields {
        JsComputedMemberExpressionFields {
            object: self.object(),
            optional_chain_token: self.optional_chain_token(),
            l_brack_token: self.l_brack_token(),
            member: self.member(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn object(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn optional_chain_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn member(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for JsComputedMemberExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsComputedMemberExpressionFields {
    pub object: SyntaxResult<AnyJsExpression>,
    pub optional_chain_token: Option<SyntaxToken>,
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub member: SyntaxResult<AnyJsExpression>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsComputedMemberName {
    pub(crate) syntax: SyntaxNode,
}
impl JsComputedMemberName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsComputedMemberNameFields {
        JsComputedMemberNameFields {
            l_brack_token: self.l_brack_token(),
            expression: self.expression(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsComputedMemberName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsComputedMemberNameFields {
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsConditionalExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsConditionalExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsConditionalExpressionFields {
        JsConditionalExpressionFields {
            test: self.test(),
            question_mark_token: self.question_mark_token(),
            consequent: self.consequent(),
            colon_token: self.colon_token(),
            alternate: self.alternate(),
        }
    }
    pub fn test(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn question_mark_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn consequent(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn alternate(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 4usize)
    }
}
impl Serialize for JsConditionalExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsConditionalExpressionFields {
    pub test: SyntaxResult<AnyJsExpression>,
    pub question_mark_token: SyntaxResult<SyntaxToken>,
    pub consequent: SyntaxResult<AnyJsExpression>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub alternate: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsConstructorClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsConstructorClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsConstructorClassMemberFields {
        JsConstructorClassMemberFields {
            modifiers: self.modifiers(),
            name: self.name(),
            parameters: self.parameters(),
            body: self.body(),
        }
    }
    pub fn modifiers(&self) -> JsConstructorModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<JsLiteralMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsConstructorParameters> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for JsConstructorClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsConstructorClassMemberFields {
    pub modifiers: JsConstructorModifierList,
    pub name: SyntaxResult<JsLiteralMemberName>,
    pub parameters: SyntaxResult<JsConstructorParameters>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsConstructorParameters {
    pub(crate) syntax: SyntaxNode,
}
impl JsConstructorParameters {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsConstructorParametersFields {
        JsConstructorParametersFields {
            l_paren_token: self.l_paren_token(),
            parameters: self.parameters(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn parameters(&self) -> JsConstructorParameterList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsConstructorParameters {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsConstructorParametersFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub parameters: JsConstructorParameterList,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsContinueStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsContinueStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsContinueStatementFields {
        JsContinueStatementFields {
            continue_token: self.continue_token(),
            label: self.label(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn continue_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn label(&self) -> Option<JsLabel> {
        support::node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for JsContinueStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsContinueStatementFields {
    pub continue_token: SyntaxResult<SyntaxToken>,
    pub label: Option<JsLabel>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsDebuggerStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsDebuggerStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsDebuggerStatementFields {
        JsDebuggerStatementFields {
            debugger_token: self.debugger_token(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn debugger_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
}
impl Serialize for JsDebuggerStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsDebuggerStatementFields {
    pub debugger_token: SyntaxResult<SyntaxToken>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsDecorator {
    pub(crate) syntax: SyntaxNode,
}
impl JsDecorator {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsDecoratorFields {
        JsDecoratorFields {
            at_token: self.at_token(),
            expression: self.expression(),
        }
    }
    pub fn at_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsDecorator> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsDecorator {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsDecoratorFields {
    pub at_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsDecorator>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsDefaultClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsDefaultClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsDefaultClauseFields {
        JsDefaultClauseFields {
            default_token: self.default_token(),
            colon_token: self.colon_token(),
            consequent: self.consequent(),
        }
    }
    pub fn default_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn consequent(&self) -> JsStatementList {
        support::list(&self.syntax, 2usize)
    }
}
impl Serialize for JsDefaultClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsDefaultClauseFields {
    pub default_token: SyntaxResult<SyntaxToken>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub consequent: JsStatementList,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsDefaultImportSpecifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsDefaultImportSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsDefaultImportSpecifierFields {
        JsDefaultImportSpecifierFields {
            local_name: self.local_name(),
        }
    }
    pub fn local_name(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 0usize)
    }
}
impl Serialize for JsDefaultImportSpecifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsDefaultImportSpecifierFields {
    pub local_name: SyntaxResult<AnyJsBinding>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsDirective {
    pub(crate) syntax: SyntaxNode,
}
impl JsDirective {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsDirectiveFields {
        JsDirectiveFields {
            value_token: self.value_token(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
}
impl Serialize for JsDirective {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsDirectiveFields {
    pub value_token: SyntaxResult<SyntaxToken>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsDoWhileStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsDoWhileStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsDoWhileStatementFields {
        JsDoWhileStatementFields {
            do_token: self.do_token(),
            body: self.body(),
            while_token: self.while_token(),
            l_paren_token: self.l_paren_token(),
            test: self.test(),
            r_paren_token: self.r_paren_token(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn do_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn while_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn test(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 6usize)
    }
}
impl Serialize for JsDoWhileStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsDoWhileStatementFields {
    pub do_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsStatement>,
    pub while_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub test: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsElseClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsElseClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsElseClauseFields {
        JsElseClauseFields {
            else_token: self.else_token(),
            alternate: self.alternate(),
        }
    }
    pub fn else_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn alternate(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsElseClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsElseClauseFields {
    pub else_token: SyntaxResult<SyntaxToken>,
    pub alternate: SyntaxResult<AnyJsStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsEmptyClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsEmptyClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsEmptyClassMemberFields {
        JsEmptyClassMemberFields {
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn semicolon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsEmptyClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsEmptyClassMemberFields {
    pub semicolon_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsEmptyStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsEmptyStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsEmptyStatementFields {
        JsEmptyStatementFields {
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn semicolon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsEmptyStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsEmptyStatementFields {
    pub semicolon_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExport {
    pub(crate) syntax: SyntaxNode,
}
impl JsExport {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportFields {
        JsExportFields {
            decorators: self.decorators(),
            export_token: self.export_token(),
            export_clause: self.export_clause(),
        }
    }
    pub fn decorators(&self) -> JsDecoratorList {
        support::list(&self.syntax, 0usize)
    }
    pub fn export_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn export_clause(&self) -> SyntaxResult<AnyJsExportClause> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsExport {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportFields {
    pub decorators: JsDecoratorList,
    pub export_token: SyntaxResult<SyntaxToken>,
    pub export_clause: SyntaxResult<AnyJsExportClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportAsClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportAsClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportAsClauseFields {
        JsExportAsClauseFields {
            as_token: self.as_token(),
            exported_name: self.exported_name(),
        }
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn exported_name(&self) -> SyntaxResult<JsLiteralExportName> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsExportAsClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportAsClauseFields {
    pub as_token: SyntaxResult<SyntaxToken>,
    pub exported_name: SyntaxResult<JsLiteralExportName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportDefaultDeclarationClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportDefaultDeclarationClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportDefaultDeclarationClauseFields {
        JsExportDefaultDeclarationClauseFields {
            default_token: self.default_token(),
            declaration: self.declaration(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn default_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn declaration(&self) -> SyntaxResult<AnyJsExportDefaultDeclaration> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for JsExportDefaultDeclarationClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportDefaultDeclarationClauseFields {
    pub default_token: SyntaxResult<SyntaxToken>,
    pub declaration: SyntaxResult<AnyJsExportDefaultDeclaration>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportDefaultExpressionClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportDefaultExpressionClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportDefaultExpressionClauseFields {
        JsExportDefaultExpressionClauseFields {
            default_token: self.default_token(),
            expression: self.expression(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn default_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for JsExportDefaultExpressionClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportDefaultExpressionClauseFields {
    pub default_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportFromClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportFromClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportFromClauseFields {
        JsExportFromClauseFields {
            type_token: self.type_token(),
            star_token: self.star_token(),
            export_as: self.export_as(),
            from_token: self.from_token(),
            source: self.source(),
            assertion: self.assertion(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn star_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn export_as(&self) -> Option<JsExportAsClause> {
        support::node(&self.syntax, 2usize)
    }
    pub fn from_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn assertion(&self) -> Option<JsImportAssertion> {
        support::node(&self.syntax, 5usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 6usize)
    }
}
impl Serialize for JsExportFromClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportFromClauseFields {
    pub type_token: Option<SyntaxToken>,
    pub star_token: SyntaxResult<SyntaxToken>,
    pub export_as: Option<JsExportAsClause>,
    pub from_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub assertion: Option<JsImportAssertion>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportNamedClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportNamedClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportNamedClauseFields {
        JsExportNamedClauseFields {
            type_token: self.type_token(),
            l_curly_token: self.l_curly_token(),
            specifiers: self.specifiers(),
            r_curly_token: self.r_curly_token(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn specifiers(&self) -> JsExportNamedSpecifierList {
        support::list(&self.syntax, 2usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
}
impl Serialize for JsExportNamedClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportNamedClauseFields {
    pub type_token: Option<SyntaxToken>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub specifiers: JsExportNamedSpecifierList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportNamedFromClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportNamedFromClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportNamedFromClauseFields {
        JsExportNamedFromClauseFields {
            type_token: self.type_token(),
            l_curly_token: self.l_curly_token(),
            specifiers: self.specifiers(),
            r_curly_token: self.r_curly_token(),
            from_token: self.from_token(),
            source: self.source(),
            assertion: self.assertion(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn specifiers(&self) -> JsExportNamedFromSpecifierList {
        support::list(&self.syntax, 2usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn from_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 5usize)
    }
    pub fn assertion(&self) -> Option<JsImportAssertion> {
        support::node(&self.syntax, 6usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 7usize)
    }
}
impl Serialize for JsExportNamedFromClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportNamedFromClauseFields {
    pub type_token: Option<SyntaxToken>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub specifiers: JsExportNamedFromSpecifierList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
    pub from_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub assertion: Option<JsImportAssertion>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportNamedFromSpecifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportNamedFromSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportNamedFromSpecifierFields {
        JsExportNamedFromSpecifierFields {
            type_token: self.type_token(),
            source_name: self.source_name(),
            export_as: self.export_as(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn source_name(&self) -> SyntaxResult<JsLiteralExportName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn export_as(&self) -> Option<JsExportAsClause> {
        support::node(&self.syntax, 2usize)
    }
}
impl Serialize for JsExportNamedFromSpecifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportNamedFromSpecifierFields {
    pub type_token: Option<SyntaxToken>,
    pub source_name: SyntaxResult<JsLiteralExportName>,
    pub export_as: Option<JsExportAsClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportNamedShorthandSpecifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportNamedShorthandSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportNamedShorthandSpecifierFields {
        JsExportNamedShorthandSpecifierFields {
            type_token: self.type_token(),
            name: self.name(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<JsReferenceIdentifier> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsExportNamedShorthandSpecifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportNamedShorthandSpecifierFields {
    pub type_token: Option<SyntaxToken>,
    pub name: SyntaxResult<JsReferenceIdentifier>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExportNamedSpecifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsExportNamedSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExportNamedSpecifierFields {
        JsExportNamedSpecifierFields {
            type_token: self.type_token(),
            local_name: self.local_name(),
            as_token: self.as_token(),
            exported_name: self.exported_name(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn local_name(&self) -> SyntaxResult<JsReferenceIdentifier> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn exported_name(&self) -> SyntaxResult<JsLiteralExportName> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for JsExportNamedSpecifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExportNamedSpecifierFields {
    pub type_token: Option<SyntaxToken>,
    pub local_name: SyntaxResult<JsReferenceIdentifier>,
    pub as_token: SyntaxResult<SyntaxToken>,
    pub exported_name: SyntaxResult<JsLiteralExportName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExpressionSnipped {
    pub(crate) syntax: SyntaxNode,
}
impl JsExpressionSnipped {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExpressionSnippedFields {
        JsExpressionSnippedFields {
            expression: self.expression(),
            eof_token: self.eof_token(),
        }
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn eof_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for JsExpressionSnipped {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExpressionSnippedFields {
    pub expression: SyntaxResult<AnyJsExpression>,
    pub eof_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExpressionStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsExpressionStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExpressionStatementFields {
        JsExpressionStatementFields {
            expression: self.expression(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
}
impl Serialize for JsExpressionStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExpressionStatementFields {
    pub expression: SyntaxResult<AnyJsExpression>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsExtendsClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsExtendsClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsExtendsClauseFields {
        JsExtendsClauseFields {
            extends_token: self.extends_token(),
            super_class: self.super_class(),
            type_arguments: self.type_arguments(),
        }
    }
    pub fn extends_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn super_class(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 2usize)
    }
}
impl Serialize for JsExtendsClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsExtendsClauseFields {
    pub extends_token: SyntaxResult<SyntaxToken>,
    pub super_class: SyntaxResult<AnyJsExpression>,
    pub type_arguments: Option<TsTypeArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsFinallyClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsFinallyClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsFinallyClauseFields {
        JsFinallyClauseFields {
            finally_token: self.finally_token(),
            body: self.body(),
        }
    }
    pub fn finally_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn body(&self) -> SyntaxResult<JsBlockStatement> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsFinallyClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsFinallyClauseFields {
    pub finally_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<JsBlockStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsForInStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsForInStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsForInStatementFields {
        JsForInStatementFields {
            for_token: self.for_token(),
            l_paren_token: self.l_paren_token(),
            initializer: self.initializer(),
            in_token: self.in_token(),
            expression: self.expression(),
            r_paren_token: self.r_paren_token(),
            body: self.body(),
        }
    }
    pub fn for_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn initializer(&self) -> SyntaxResult<AnyJsForInOrOfInitializer> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn in_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 6usize)
    }
}
impl Serialize for JsForInStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsForInStatementFields {
    pub for_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub initializer: SyntaxResult<AnyJsForInOrOfInitializer>,
    pub in_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsForOfStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsForOfStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsForOfStatementFields {
        JsForOfStatementFields {
            for_token: self.for_token(),
            await_token: self.await_token(),
            l_paren_token: self.l_paren_token(),
            initializer: self.initializer(),
            of_token: self.of_token(),
            expression: self.expression(),
            r_paren_token: self.r_paren_token(),
            body: self.body(),
        }
    }
    pub fn for_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn await_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn initializer(&self) -> SyntaxResult<AnyJsForInOrOfInitializer> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn of_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 5usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 6usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 7usize)
    }
}
impl Serialize for JsForOfStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsForOfStatementFields {
    pub for_token: SyntaxResult<SyntaxToken>,
    pub await_token: Option<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub initializer: SyntaxResult<AnyJsForInOrOfInitializer>,
    pub of_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsForStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsForStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsForStatementFields {
        JsForStatementFields {
            for_token: self.for_token(),
            l_paren_token: self.l_paren_token(),
            initializer: self.initializer(),
            first_semi_token: self.first_semi_token(),
            test: self.test(),
            second_semi_token: self.second_semi_token(),
            update: self.update(),
            r_paren_token: self.r_paren_token(),
            body: self.body(),
        }
    }
    pub fn for_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn initializer(&self) -> Option<AnyJsForInitializer> {
        support::node(&self.syntax, 2usize)
    }
    pub fn first_semi_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn test(&self) -> Option<AnyJsExpression> {
        support::node(&self.syntax, 4usize)
    }
    pub fn second_semi_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
    pub fn update(&self) -> Option<AnyJsExpression> {
        support::node(&self.syntax, 6usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 7usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 8usize)
    }
}
impl Serialize for JsForStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsForStatementFields {
    pub for_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub initializer: Option<AnyJsForInitializer>,
    pub first_semi_token: SyntaxResult<SyntaxToken>,
    pub test: Option<AnyJsExpression>,
    pub second_semi_token: SyntaxResult<SyntaxToken>,
    pub update: Option<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsForVariableDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl JsForVariableDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsForVariableDeclarationFields {
        JsForVariableDeclarationFields {
            await_token: self.await_token(),
            kind_token: self.kind_token(),
            declarator: self.declarator(),
        }
    }
    pub fn await_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn kind_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn declarator(&self) -> SyntaxResult<JsVariableDeclarator> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsForVariableDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsForVariableDeclarationFields {
    pub await_token: Option<SyntaxToken>,
    pub kind_token: SyntaxResult<SyntaxToken>,
    pub declarator: SyntaxResult<JsVariableDeclarator>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsFormalParameter {
    pub(crate) syntax: SyntaxNode,
}
impl JsFormalParameter {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsFormalParameterFields {
        JsFormalParameterFields {
            decorators: self.decorators(),
            binding: self.binding(),
            question_mark_token: self.question_mark_token(),
            type_annotation: self.type_annotation(),
            initializer: self.initializer(),
        }
    }
    pub fn decorators(&self) -> JsDecoratorList {
        support::list(&self.syntax, 0usize)
    }
    pub fn binding(&self) -> SyntaxResult<AnyJsBindingPattern> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn question_mark_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 3usize)
    }
    pub fn initializer(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 4usize)
    }
}
impl Serialize for JsFormalParameter {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsFormalParameterFields {
    pub decorators: JsDecoratorList,
    pub binding: SyntaxResult<AnyJsBindingPattern>,
    pub question_mark_token: Option<SyntaxToken>,
    pub type_annotation: Option<TsTypeAnnotation>,
    pub initializer: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsFunctionBody {
    pub(crate) syntax: SyntaxNode,
}
impl JsFunctionBody {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsFunctionBodyFields {
        JsFunctionBodyFields {
            l_curly_token: self.l_curly_token(),
            directives: self.directives(),
            statements: self.statements(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn directives(&self) -> JsDirectiveList {
        support::list(&self.syntax, 1usize)
    }
    pub fn statements(&self) -> JsStatementList {
        support::list(&self.syntax, 2usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsFunctionBody {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsFunctionBodyFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub directives: JsDirectiveList,
    pub statements: JsStatementList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsFunctionDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl JsFunctionDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsFunctionDeclarationFields {
        JsFunctionDeclarationFields {
            async_token: self.async_token(),
            function_token: self.function_token(),
            star_token: self.star_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            body: self.body(),
        }
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn function_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn star_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn id(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 4usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 5usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 6usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 7usize)
    }
}
impl Serialize for JsFunctionDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsFunctionDeclarationFields {
    pub async_token: Option<SyntaxToken>,
    pub function_token: SyntaxResult<SyntaxToken>,
    pub star_token: Option<SyntaxToken>,
    pub id: SyntaxResult<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsFunctionExportDefaultDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl JsFunctionExportDefaultDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsFunctionExportDefaultDeclarationFields {
        JsFunctionExportDefaultDeclarationFields {
            async_token: self.async_token(),
            function_token: self.function_token(),
            star_token: self.star_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            body: self.body(),
        }
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn function_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn star_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn id(&self) -> Option<AnyJsBinding> {
        support::node(&self.syntax, 3usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 4usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 5usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 6usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 7usize)
    }
}
impl Serialize for JsFunctionExportDefaultDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsFunctionExportDefaultDeclarationFields {
    pub async_token: Option<SyntaxToken>,
    pub function_token: SyntaxResult<SyntaxToken>,
    pub star_token: Option<SyntaxToken>,
    pub id: Option<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsFunctionExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsFunctionExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsFunctionExpressionFields {
        JsFunctionExpressionFields {
            async_token: self.async_token(),
            function_token: self.function_token(),
            star_token: self.star_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            body: self.body(),
        }
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn function_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn star_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn id(&self) -> Option<AnyJsBinding> {
        support::node(&self.syntax, 3usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 4usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 5usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 6usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 7usize)
    }
}
impl Serialize for JsFunctionExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsFunctionExpressionFields {
    pub async_token: Option<SyntaxToken>,
    pub function_token: SyntaxResult<SyntaxToken>,
    pub star_token: Option<SyntaxToken>,
    pub id: Option<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsGetterClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsGetterClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsGetterClassMemberFields {
        JsGetterClassMemberFields {
            modifiers: self.modifiers(),
            get_token: self.get_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            r_paren_token: self.r_paren_token(),
            return_type: self.return_type(),
            body: self.body(),
        }
    }
    pub fn modifiers(&self) -> JsMethodModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn get_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn return_type(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 5usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 6usize)
    }
}
impl Serialize for JsGetterClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsGetterClassMemberFields {
    pub modifiers: JsMethodModifierList,
    pub get_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub return_type: Option<TsTypeAnnotation>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsGetterObjectMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsGetterObjectMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsGetterObjectMemberFields {
        JsGetterObjectMemberFields {
            get_token: self.get_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            r_paren_token: self.r_paren_token(),
            return_type: self.return_type(),
            body: self.body(),
        }
    }
    pub fn get_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn return_type(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 4usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 5usize)
    }
}
impl Serialize for JsGetterObjectMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsGetterObjectMemberFields {
    pub get_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub return_type: Option<TsTypeAnnotation>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsIdentifierAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl JsIdentifierAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsIdentifierAssignmentFields {
        JsIdentifierAssignmentFields {
            name_token: self.name_token(),
        }
    }
    pub fn name_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsIdentifierAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsIdentifierAssignmentFields {
    pub name_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsIdentifierBinding {
    pub(crate) syntax: SyntaxNode,
}
impl JsIdentifierBinding {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsIdentifierBindingFields {
        JsIdentifierBindingFields {
            name_token: self.name_token(),
        }
    }
    pub fn name_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsIdentifierBinding {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsIdentifierBindingFields {
    pub name_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsIdentifierExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsIdentifierExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsIdentifierExpressionFields {
        JsIdentifierExpressionFields { name: self.name() }
    }
    pub fn name(&self) -> SyntaxResult<JsReferenceIdentifier> {
        support::required_node(&self.syntax, 0usize)
    }
}
impl Serialize for JsIdentifierExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsIdentifierExpressionFields {
    pub name: SyntaxResult<JsReferenceIdentifier>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsIfStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsIfStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsIfStatementFields {
        JsIfStatementFields {
            if_token: self.if_token(),
            l_paren_token: self.l_paren_token(),
            test: self.test(),
            r_paren_token: self.r_paren_token(),
            consequent: self.consequent(),
            else_clause: self.else_clause(),
        }
    }
    pub fn if_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn test(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn consequent(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn else_clause(&self) -> Option<JsElseClause> {
        support::node(&self.syntax, 5usize)
    }
}
impl Serialize for JsIfStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsIfStatementFields {
    pub if_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub test: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub consequent: SyntaxResult<AnyJsStatement>,
    pub else_clause: Option<JsElseClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImport {
    pub(crate) syntax: SyntaxNode,
}
impl JsImport {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportFields {
        JsImportFields {
            import_token: self.import_token(),
            import_clause: self.import_clause(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn import_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn import_clause(&self) -> SyntaxResult<AnyJsImportClause> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for JsImport {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportFields {
    pub import_token: SyntaxResult<SyntaxToken>,
    pub import_clause: SyntaxResult<AnyJsImportClause>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportAssertion {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportAssertion {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportAssertionFields {
        JsImportAssertionFields {
            with_token: self.with_token(),
            l_curly_token: self.l_curly_token(),
            assertions: self.assertions(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn with_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn assertions(&self) -> JsImportAssertionEntryList {
        support::list(&self.syntax, 2usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsImportAssertion {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportAssertionFields {
    pub with_token: SyntaxResult<SyntaxToken>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub assertions: JsImportAssertionEntryList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportAssertionEntry {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportAssertionEntry {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportAssertionEntryFields {
        JsImportAssertionEntryFields {
            key: self.key(),
            colon_token: self.colon_token(),
            value_token: self.value_token(),
        }
    }
    pub fn key(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsImportAssertionEntry {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportAssertionEntryFields {
    pub key: SyntaxResult<SyntaxToken>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportBareClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportBareClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportBareClauseFields {
        JsImportBareClauseFields {
            source: self.source(),
            assertion: self.assertion(),
        }
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn assertion(&self) -> Option<JsImportAssertion> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for JsImportBareClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportBareClauseFields {
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub assertion: Option<JsImportAssertion>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportCallExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportCallExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportCallExpressionFields {
        JsImportCallExpressionFields {
            import_token: self.import_token(),
            dot_token: self.dot_token(),
            phase: self.phase(),
            arguments: self.arguments(),
        }
    }
    pub fn import_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn dot_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn phase(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn arguments(&self) -> SyntaxResult<JsCallArguments> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for JsImportCallExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportCallExpressionFields {
    pub import_token: SyntaxResult<SyntaxToken>,
    pub dot_token: Option<SyntaxToken>,
    pub phase: Option<SyntaxToken>,
    pub arguments: SyntaxResult<JsCallArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportCombinedClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportCombinedClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportCombinedClauseFields {
        JsImportCombinedClauseFields {
            default_specifier: self.default_specifier(),
            comma_token: self.comma_token(),
            specifier: self.specifier(),
            from_token: self.from_token(),
            source: self.source(),
            assertion: self.assertion(),
        }
    }
    pub fn default_specifier(&self) -> SyntaxResult<JsDefaultImportSpecifier> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn comma_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn specifier(&self) -> SyntaxResult<AnyJsCombinedSpecifier> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn from_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn assertion(&self) -> Option<JsImportAssertion> {
        support::node(&self.syntax, 5usize)
    }
}
impl Serialize for JsImportCombinedClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportCombinedClauseFields {
    pub default_specifier: SyntaxResult<JsDefaultImportSpecifier>,
    pub comma_token: SyntaxResult<SyntaxToken>,
    pub specifier: SyntaxResult<AnyJsCombinedSpecifier>,
    pub from_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub assertion: Option<JsImportAssertion>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportDefaultClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportDefaultClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportDefaultClauseFields {
        JsImportDefaultClauseFields {
            type_token: self.type_token(),
            phase_token: self.phase_token(),
            default_specifier: self.default_specifier(),
            from_token: self.from_token(),
            source: self.source(),
            assertion: self.assertion(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn phase_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn default_specifier(&self) -> SyntaxResult<JsDefaultImportSpecifier> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn from_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn assertion(&self) -> Option<JsImportAssertion> {
        support::node(&self.syntax, 5usize)
    }
}
impl Serialize for JsImportDefaultClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportDefaultClauseFields {
    pub type_token: Option<SyntaxToken>,
    pub phase_token: Option<SyntaxToken>,
    pub default_specifier: SyntaxResult<JsDefaultImportSpecifier>,
    pub from_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub assertion: Option<JsImportAssertion>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportMetaExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportMetaExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportMetaExpressionFields {
        JsImportMetaExpressionFields {
            import_token: self.import_token(),
            dot_token: self.dot_token(),
            meta_token: self.meta_token(),
        }
    }
    pub fn import_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn dot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn meta_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsImportMetaExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportMetaExpressionFields {
    pub import_token: SyntaxResult<SyntaxToken>,
    pub dot_token: SyntaxResult<SyntaxToken>,
    pub meta_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportNamedClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportNamedClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportNamedClauseFields {
        JsImportNamedClauseFields {
            type_token: self.type_token(),
            named_specifiers: self.named_specifiers(),
            from_token: self.from_token(),
            source: self.source(),
            assertion: self.assertion(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn named_specifiers(&self) -> SyntaxResult<JsNamedImportSpecifiers> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn from_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn assertion(&self) -> Option<JsImportAssertion> {
        support::node(&self.syntax, 4usize)
    }
}
impl Serialize for JsImportNamedClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportNamedClauseFields {
    pub type_token: Option<SyntaxToken>,
    pub named_specifiers: SyntaxResult<JsNamedImportSpecifiers>,
    pub from_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub assertion: Option<JsImportAssertion>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsImportNamespaceClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsImportNamespaceClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsImportNamespaceClauseFields {
        JsImportNamespaceClauseFields {
            type_token: self.type_token(),
            phase_token: self.phase_token(),
            namespace_specifier: self.namespace_specifier(),
            from_token: self.from_token(),
            source: self.source(),
            assertion: self.assertion(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn phase_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn namespace_specifier(&self) -> SyntaxResult<JsNamespaceImportSpecifier> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn from_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn assertion(&self) -> Option<JsImportAssertion> {
        support::node(&self.syntax, 5usize)
    }
}
impl Serialize for JsImportNamespaceClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsImportNamespaceClauseFields {
    pub type_token: Option<SyntaxToken>,
    pub phase_token: Option<SyntaxToken>,
    pub namespace_specifier: SyntaxResult<JsNamespaceImportSpecifier>,
    pub from_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub assertion: Option<JsImportAssertion>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsInExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsInExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsInExpressionFields {
        JsInExpressionFields {
            property: self.property(),
            in_token: self.in_token(),
            object: self.object(),
        }
    }
    pub fn property(&self) -> SyntaxResult<AnyJsInProperty> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn in_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn object(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsInExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsInExpressionFields {
    pub property: SyntaxResult<AnyJsInProperty>,
    pub in_token: SyntaxResult<SyntaxToken>,
    pub object: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsInitializerClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsInitializerClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsInitializerClauseFields {
        JsInitializerClauseFields {
            eq_token: self.eq_token(),
            expression: self.expression(),
        }
    }
    pub fn eq_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsInitializerClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsInitializerClauseFields {
    pub eq_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsInstanceofExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsInstanceofExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsInstanceofExpressionFields {
        JsInstanceofExpressionFields {
            left: self.left(),
            instanceof_token: self.instanceof_token(),
            right: self.right(),
        }
    }
    pub fn left(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn instanceof_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn right(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsInstanceofExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsInstanceofExpressionFields {
    pub left: SyntaxResult<AnyJsExpression>,
    pub instanceof_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsLabel {
    pub(crate) syntax: SyntaxNode,
}
impl JsLabel {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsLabelFields {
        JsLabelFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsLabel {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsLabelFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsLabeledStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsLabeledStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsLabeledStatementFields {
        JsLabeledStatementFields {
            label: self.label(),
            colon_token: self.colon_token(),
            body: self.body(),
        }
    }
    pub fn label(&self) -> SyntaxResult<JsLabel> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsLabeledStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsLabeledStatementFields {
    pub label: SyntaxResult<JsLabel>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsLiteralExportName {
    pub(crate) syntax: SyntaxNode,
}
impl JsLiteralExportName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsLiteralExportNameFields {
        JsLiteralExportNameFields {
            value: self.value(),
        }
    }
    pub fn value(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsLiteralExportName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsLiteralExportNameFields {
    pub value: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsLiteralMemberName {
    pub(crate) syntax: SyntaxNode,
}
impl JsLiteralMemberName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsLiteralMemberNameFields {
        JsLiteralMemberNameFields {
            value: self.value(),
        }
    }
    pub fn value(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsLiteralMemberName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsLiteralMemberNameFields {
    pub value: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsLogicalExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsLogicalExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsLogicalExpressionFields {
        JsLogicalExpressionFields {
            left: self.left(),
            operator_token: self.operator_token(),
            right: self.right(),
        }
    }
    pub fn left(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn right(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsLogicalExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsLogicalExpressionFields {
    pub left: SyntaxResult<AnyJsExpression>,
    pub operator_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsMetavariable {
    pub(crate) syntax: SyntaxNode,
}
impl JsMetavariable {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsMetavariableFields {
        JsMetavariableFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsMetavariable {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsMetavariableFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsMethodClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsMethodClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsMethodClassMemberFields {
        JsMethodClassMemberFields {
            modifiers: self.modifiers(),
            async_token: self.async_token(),
            star_token: self.star_token(),
            name: self.name(),
            question_mark_token: self.question_mark_token(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            body: self.body(),
        }
    }
    pub fn modifiers(&self) -> JsMethodModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn star_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn question_mark_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 5usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 6usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 7usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 8usize)
    }
}
impl Serialize for JsMethodClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsMethodClassMemberFields {
    pub modifiers: JsMethodModifierList,
    pub async_token: Option<SyntaxToken>,
    pub star_token: Option<SyntaxToken>,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub question_mark_token: Option<SyntaxToken>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsMethodObjectMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsMethodObjectMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsMethodObjectMemberFields {
        JsMethodObjectMemberFields {
            async_token: self.async_token(),
            star_token: self.star_token(),
            name: self.name(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            body: self.body(),
        }
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn star_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 3usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 5usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 6usize)
    }
}
impl Serialize for JsMethodObjectMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsMethodObjectMemberFields {
    pub async_token: Option<SyntaxToken>,
    pub star_token: Option<SyntaxToken>,
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsModule {
    pub(crate) syntax: SyntaxNode,
}
impl JsModule {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsModuleFields {
        JsModuleFields {
            bom_token: self.bom_token(),
            interpreter_token: self.interpreter_token(),
            directives: self.directives(),
            items: self.items(),
            eof_token: self.eof_token(),
        }
    }
    pub fn bom_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn interpreter_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn directives(&self) -> JsDirectiveList {
        support::list(&self.syntax, 2usize)
    }
    pub fn items(&self) -> JsModuleItemList {
        support::list(&self.syntax, 3usize)
    }
    pub fn eof_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for JsModule {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsModuleFields {
    pub bom_token: Option<SyntaxToken>,
    pub interpreter_token: Option<SyntaxToken>,
    pub directives: JsDirectiveList,
    pub items: JsModuleItemList,
    pub eof_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsModuleSource {
    pub(crate) syntax: SyntaxNode,
}
impl JsModuleSource {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsModuleSourceFields {
        JsModuleSourceFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsModuleSource {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsModuleSourceFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsName {
    pub(crate) syntax: SyntaxNode,
}
impl JsName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNameFields {
        JsNameFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNameFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsNamedImportSpecifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsNamedImportSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNamedImportSpecifierFields {
        JsNamedImportSpecifierFields {
            type_token: self.type_token(),
            name: self.name(),
            as_token: self.as_token(),
            local_name: self.local_name(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<JsLiteralExportName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn local_name(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for JsNamedImportSpecifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNamedImportSpecifierFields {
    pub type_token: Option<SyntaxToken>,
    pub name: SyntaxResult<JsLiteralExportName>,
    pub as_token: SyntaxResult<SyntaxToken>,
    pub local_name: SyntaxResult<AnyJsBinding>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsNamedImportSpecifiers {
    pub(crate) syntax: SyntaxNode,
}
impl JsNamedImportSpecifiers {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNamedImportSpecifiersFields {
        JsNamedImportSpecifiersFields {
            l_curly_token: self.l_curly_token(),
            specifiers: self.specifiers(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn specifiers(&self) -> JsNamedImportSpecifierList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsNamedImportSpecifiers {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNamedImportSpecifiersFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub specifiers: JsNamedImportSpecifierList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsNamespaceImportSpecifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsNamespaceImportSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNamespaceImportSpecifierFields {
        JsNamespaceImportSpecifierFields {
            star_token: self.star_token(),
            as_token: self.as_token(),
            local_name: self.local_name(),
        }
    }
    pub fn star_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn local_name(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsNamespaceImportSpecifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNamespaceImportSpecifierFields {
    pub star_token: SyntaxResult<SyntaxToken>,
    pub as_token: SyntaxResult<SyntaxToken>,
    pub local_name: SyntaxResult<AnyJsBinding>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsNewExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsNewExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNewExpressionFields {
        JsNewExpressionFields {
            new_token: self.new_token(),
            callee: self.callee(),
            type_arguments: self.type_arguments(),
            arguments: self.arguments(),
        }
    }
    pub fn new_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn callee(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 2usize)
    }
    pub fn arguments(&self) -> Option<JsCallArguments> {
        support::node(&self.syntax, 3usize)
    }
}
impl Serialize for JsNewExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNewExpressionFields {
    pub new_token: SyntaxResult<SyntaxToken>,
    pub callee: SyntaxResult<AnyJsExpression>,
    pub type_arguments: Option<TsTypeArguments>,
    pub arguments: Option<JsCallArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsNewTargetExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsNewTargetExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNewTargetExpressionFields {
        JsNewTargetExpressionFields {
            new_token: self.new_token(),
            dot_token: self.dot_token(),
            target_token: self.target_token(),
        }
    }
    pub fn new_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn dot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn target_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsNewTargetExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNewTargetExpressionFields {
    pub new_token: SyntaxResult<SyntaxToken>,
    pub dot_token: SyntaxResult<SyntaxToken>,
    pub target_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsNullLiteralExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsNullLiteralExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNullLiteralExpressionFields {
        JsNullLiteralExpressionFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsNullLiteralExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNullLiteralExpressionFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsNumberLiteralExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsNumberLiteralExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsNumberLiteralExpressionFields {
        JsNumberLiteralExpressionFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsNumberLiteralExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsNumberLiteralExpressionFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectAssignmentPattern {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectAssignmentPattern {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectAssignmentPatternFields {
        JsObjectAssignmentPatternFields {
            l_curly_token: self.l_curly_token(),
            properties: self.properties(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn properties(&self) -> JsObjectAssignmentPatternPropertyList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsObjectAssignmentPattern {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectAssignmentPatternFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub properties: JsObjectAssignmentPatternPropertyList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectAssignmentPatternProperty {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectAssignmentPatternProperty {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectAssignmentPatternPropertyFields {
        JsObjectAssignmentPatternPropertyFields {
            member: self.member(),
            colon_token: self.colon_token(),
            pattern: self.pattern(),
            init: self.init(),
        }
    }
    pub fn member(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn pattern(&self) -> SyntaxResult<AnyJsAssignmentPattern> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn init(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 3usize)
    }
}
impl Serialize for JsObjectAssignmentPatternProperty {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectAssignmentPatternPropertyFields {
    pub member: SyntaxResult<AnyJsObjectMemberName>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub pattern: SyntaxResult<AnyJsAssignmentPattern>,
    pub init: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectAssignmentPatternRest {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectAssignmentPatternRest {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectAssignmentPatternRestFields {
        JsObjectAssignmentPatternRestFields {
            dotdotdot_token: self.dotdotdot_token(),
            target: self.target(),
        }
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn target(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsObjectAssignmentPatternRest {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectAssignmentPatternRestFields {
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub target: SyntaxResult<AnyJsAssignment>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectAssignmentPatternShorthandProperty {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectAssignmentPatternShorthandProperty {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectAssignmentPatternShorthandPropertyFields {
        JsObjectAssignmentPatternShorthandPropertyFields {
            identifier: self.identifier(),
            init: self.init(),
        }
    }
    pub fn identifier(&self) -> SyntaxResult<JsIdentifierAssignment> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn init(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for JsObjectAssignmentPatternShorthandProperty {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectAssignmentPatternShorthandPropertyFields {
    pub identifier: SyntaxResult<JsIdentifierAssignment>,
    pub init: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectBindingPattern {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectBindingPattern {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectBindingPatternFields {
        JsObjectBindingPatternFields {
            l_curly_token: self.l_curly_token(),
            properties: self.properties(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn properties(&self) -> JsObjectBindingPatternPropertyList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsObjectBindingPattern {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectBindingPatternFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub properties: JsObjectBindingPatternPropertyList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectBindingPatternProperty {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectBindingPatternProperty {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectBindingPatternPropertyFields {
        JsObjectBindingPatternPropertyFields {
            member: self.member(),
            colon_token: self.colon_token(),
            pattern: self.pattern(),
            init: self.init(),
        }
    }
    pub fn member(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn pattern(&self) -> SyntaxResult<AnyJsBindingPattern> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn init(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 3usize)
    }
}
impl Serialize for JsObjectBindingPatternProperty {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectBindingPatternPropertyFields {
    pub member: SyntaxResult<AnyJsObjectMemberName>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub pattern: SyntaxResult<AnyJsBindingPattern>,
    pub init: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectBindingPatternRest {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectBindingPatternRest {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectBindingPatternRestFields {
        JsObjectBindingPatternRestFields {
            dotdotdot_token: self.dotdotdot_token(),
            binding: self.binding(),
        }
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn binding(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsObjectBindingPatternRest {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectBindingPatternRestFields {
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub binding: SyntaxResult<AnyJsBinding>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectBindingPatternShorthandProperty {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectBindingPatternShorthandProperty {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectBindingPatternShorthandPropertyFields {
        JsObjectBindingPatternShorthandPropertyFields {
            identifier: self.identifier(),
            init: self.init(),
        }
    }
    pub fn identifier(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn init(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for JsObjectBindingPatternShorthandProperty {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectBindingPatternShorthandPropertyFields {
    pub identifier: SyntaxResult<AnyJsBinding>,
    pub init: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsObjectExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsObjectExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsObjectExpressionFields {
        JsObjectExpressionFields {
            l_curly_token: self.l_curly_token(),
            members: self.members(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn members(&self) -> JsObjectMemberList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsObjectExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsObjectExpressionFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub members: JsObjectMemberList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsParameters {
    pub(crate) syntax: SyntaxNode,
}
impl JsParameters {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsParametersFields {
        JsParametersFields {
            l_paren_token: self.l_paren_token(),
            items: self.items(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn items(&self) -> JsParameterList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsParameters {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsParametersFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub items: JsParameterList,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsParenthesizedAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl JsParenthesizedAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsParenthesizedAssignmentFields {
        JsParenthesizedAssignmentFields {
            l_paren_token: self.l_paren_token(),
            assignment: self.assignment(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn assignment(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsParenthesizedAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsParenthesizedAssignmentFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub assignment: SyntaxResult<AnyJsAssignment>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsParenthesizedExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsParenthesizedExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsParenthesizedExpressionFields {
        JsParenthesizedExpressionFields {
            l_paren_token: self.l_paren_token(),
            expression: self.expression(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsParenthesizedExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsParenthesizedExpressionFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsPostUpdateExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsPostUpdateExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsPostUpdateExpressionFields {
        JsPostUpdateExpressionFields {
            operand: self.operand(),
            operator_token: self.operator_token(),
        }
    }
    pub fn operand(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for JsPostUpdateExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsPostUpdateExpressionFields {
    pub operand: SyntaxResult<AnyJsAssignment>,
    pub operator_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsPreUpdateExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsPreUpdateExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsPreUpdateExpressionFields {
        JsPreUpdateExpressionFields {
            operator_token: self.operator_token(),
            operand: self.operand(),
        }
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn operand(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsPreUpdateExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsPreUpdateExpressionFields {
    pub operator_token: SyntaxResult<SyntaxToken>,
    pub operand: SyntaxResult<AnyJsAssignment>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsPrivateClassMemberName {
    pub(crate) syntax: SyntaxNode,
}
impl JsPrivateClassMemberName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsPrivateClassMemberNameFields {
        JsPrivateClassMemberNameFields {
            hash_token: self.hash_token(),
            id_token: self.id_token(),
        }
    }
    pub fn hash_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn id_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for JsPrivateClassMemberName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsPrivateClassMemberNameFields {
    pub hash_token: SyntaxResult<SyntaxToken>,
    pub id_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsPrivateName {
    pub(crate) syntax: SyntaxNode,
}
impl JsPrivateName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsPrivateNameFields {
        JsPrivateNameFields {
            hash_token: self.hash_token(),
            value_token: self.value_token(),
        }
    }
    pub fn hash_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for JsPrivateName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsPrivateNameFields {
    pub hash_token: SyntaxResult<SyntaxToken>,
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsPropertyClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsPropertyClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsPropertyClassMemberFields {
        JsPropertyClassMemberFields {
            modifiers: self.modifiers(),
            name: self.name(),
            property_annotation: self.property_annotation(),
            value: self.value(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> JsPropertyModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn property_annotation(&self) -> Option<AnyTsPropertyAnnotation> {
        support::node(&self.syntax, 2usize)
    }
    pub fn value(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 3usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
}
impl Serialize for JsPropertyClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsPropertyClassMemberFields {
    pub modifiers: JsPropertyModifierList,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub property_annotation: Option<AnyTsPropertyAnnotation>,
    pub value: Option<JsInitializerClause>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsPropertyObjectMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsPropertyObjectMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsPropertyObjectMemberFields {
        JsPropertyObjectMemberFields {
            name: self.name(),
            colon_token: self.colon_token(),
            value: self.value(),
        }
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn value(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsPropertyObjectMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsPropertyObjectMemberFields {
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub value: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsReferenceIdentifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsReferenceIdentifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsReferenceIdentifierFields {
        JsReferenceIdentifierFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsReferenceIdentifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsReferenceIdentifierFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsRegexLiteralExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsRegexLiteralExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsRegexLiteralExpressionFields {
        JsRegexLiteralExpressionFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsRegexLiteralExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsRegexLiteralExpressionFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsRestParameter {
    pub(crate) syntax: SyntaxNode,
}
impl JsRestParameter {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsRestParameterFields {
        JsRestParameterFields {
            decorators: self.decorators(),
            dotdotdot_token: self.dotdotdot_token(),
            binding: self.binding(),
            type_annotation: self.type_annotation(),
        }
    }
    pub fn decorators(&self) -> JsDecoratorList {
        support::list(&self.syntax, 0usize)
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn binding(&self) -> SyntaxResult<AnyJsBindingPattern> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 3usize)
    }
}
impl Serialize for JsRestParameter {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsRestParameterFields {
    pub decorators: JsDecoratorList,
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub binding: SyntaxResult<AnyJsBindingPattern>,
    pub type_annotation: Option<TsTypeAnnotation>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsReturnStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsReturnStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsReturnStatementFields {
        JsReturnStatementFields {
            return_token: self.return_token(),
            argument: self.argument(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn return_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn argument(&self) -> Option<AnyJsExpression> {
        support::node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for JsReturnStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsReturnStatementFields {
    pub return_token: SyntaxResult<SyntaxToken>,
    pub argument: Option<AnyJsExpression>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsScript {
    pub(crate) syntax: SyntaxNode,
}
impl JsScript {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsScriptFields {
        JsScriptFields {
            bom_token: self.bom_token(),
            interpreter_token: self.interpreter_token(),
            directives: self.directives(),
            statements: self.statements(),
            eof_token: self.eof_token(),
        }
    }
    pub fn bom_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn interpreter_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn directives(&self) -> JsDirectiveList {
        support::list(&self.syntax, 2usize)
    }
    pub fn statements(&self) -> JsStatementList {
        support::list(&self.syntax, 3usize)
    }
    pub fn eof_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for JsScript {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsScriptFields {
    pub bom_token: Option<SyntaxToken>,
    pub interpreter_token: Option<SyntaxToken>,
    pub directives: JsDirectiveList,
    pub statements: JsStatementList,
    pub eof_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsSequenceExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsSequenceExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsSequenceExpressionFields {
        JsSequenceExpressionFields {
            left: self.left(),
            comma_token: self.comma_token(),
            right: self.right(),
        }
    }
    pub fn left(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn comma_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn right(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsSequenceExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsSequenceExpressionFields {
    pub left: SyntaxResult<AnyJsExpression>,
    pub comma_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsSetterClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsSetterClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsSetterClassMemberFields {
        JsSetterClassMemberFields {
            modifiers: self.modifiers(),
            set_token: self.set_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            parameter: self.parameter(),
            comma_token: self.comma_token(),
            r_paren_token: self.r_paren_token(),
            body: self.body(),
        }
    }
    pub fn modifiers(&self) -> JsMethodModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn set_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn parameter(&self) -> SyntaxResult<AnyJsFormalParameter> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn comma_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 6usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 7usize)
    }
}
impl Serialize for JsSetterClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsSetterClassMemberFields {
    pub modifiers: JsMethodModifierList,
    pub set_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub parameter: SyntaxResult<AnyJsFormalParameter>,
    pub comma_token: Option<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsSetterObjectMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsSetterObjectMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsSetterObjectMemberFields {
        JsSetterObjectMemberFields {
            set_token: self.set_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            parameter: self.parameter(),
            comma_token: self.comma_token(),
            r_paren_token: self.r_paren_token(),
            body: self.body(),
        }
    }
    pub fn set_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn parameter(&self) -> SyntaxResult<AnyJsFormalParameter> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn comma_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
    pub fn body(&self) -> SyntaxResult<JsFunctionBody> {
        support::required_node(&self.syntax, 6usize)
    }
}
impl Serialize for JsSetterObjectMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsSetterObjectMemberFields {
    pub set_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub parameter: SyntaxResult<AnyJsFormalParameter>,
    pub comma_token: Option<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<JsFunctionBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsShorthandNamedImportSpecifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsShorthandNamedImportSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsShorthandNamedImportSpecifierFields {
        JsShorthandNamedImportSpecifierFields {
            type_token: self.type_token(),
            local_name: self.local_name(),
        }
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn local_name(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsShorthandNamedImportSpecifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsShorthandNamedImportSpecifierFields {
    pub type_token: Option<SyntaxToken>,
    pub local_name: SyntaxResult<AnyJsBinding>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsShorthandPropertyObjectMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsShorthandPropertyObjectMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsShorthandPropertyObjectMemberFields {
        JsShorthandPropertyObjectMemberFields { name: self.name() }
    }
    pub fn name(&self) -> SyntaxResult<JsReferenceIdentifier> {
        support::required_node(&self.syntax, 0usize)
    }
}
impl Serialize for JsShorthandPropertyObjectMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsShorthandPropertyObjectMemberFields {
    pub name: SyntaxResult<JsReferenceIdentifier>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsSpread {
    pub(crate) syntax: SyntaxNode,
}
impl JsSpread {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsSpreadFields {
        JsSpreadFields {
            dotdotdot_token: self.dotdotdot_token(),
            argument: self.argument(),
        }
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn argument(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsSpread {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsSpreadFields {
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub argument: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsStaticInitializationBlockClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl JsStaticInitializationBlockClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsStaticInitializationBlockClassMemberFields {
        JsStaticInitializationBlockClassMemberFields {
            static_token: self.static_token(),
            l_curly_token: self.l_curly_token(),
            statements: self.statements(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn static_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn statements(&self) -> JsStatementList {
        support::list(&self.syntax, 2usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsStaticInitializationBlockClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsStaticInitializationBlockClassMemberFields {
    pub static_token: SyntaxResult<SyntaxToken>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub statements: JsStatementList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsStaticMemberAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl JsStaticMemberAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsStaticMemberAssignmentFields {
        JsStaticMemberAssignmentFields {
            object: self.object(),
            dot_token: self.dot_token(),
            member: self.member(),
        }
    }
    pub fn object(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn dot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn member(&self) -> SyntaxResult<AnyJsName> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsStaticMemberAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsStaticMemberAssignmentFields {
    pub object: SyntaxResult<AnyJsExpression>,
    pub dot_token: SyntaxResult<SyntaxToken>,
    pub member: SyntaxResult<AnyJsName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsStaticMemberExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsStaticMemberExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsStaticMemberExpressionFields {
        JsStaticMemberExpressionFields {
            object: self.object(),
            operator_token: self.operator_token(),
            member: self.member(),
        }
    }
    pub fn object(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn member(&self) -> SyntaxResult<AnyJsName> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsStaticMemberExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsStaticMemberExpressionFields {
    pub object: SyntaxResult<AnyJsExpression>,
    pub operator_token: SyntaxResult<SyntaxToken>,
    pub member: SyntaxResult<AnyJsName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsStaticModifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsStaticModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsStaticModifierFields {
        JsStaticModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsStaticModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsStaticModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsStringLiteralExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsStringLiteralExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsStringLiteralExpressionFields {
        JsStringLiteralExpressionFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsStringLiteralExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsStringLiteralExpressionFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsSuperExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsSuperExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsSuperExpressionFields {
        JsSuperExpressionFields {
            super_token: self.super_token(),
        }
    }
    pub fn super_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsSuperExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsSuperExpressionFields {
    pub super_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsSwitchStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsSwitchStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsSwitchStatementFields {
        JsSwitchStatementFields {
            switch_token: self.switch_token(),
            l_paren_token: self.l_paren_token(),
            discriminant: self.discriminant(),
            r_paren_token: self.r_paren_token(),
            l_curly_token: self.l_curly_token(),
            cases: self.cases(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn switch_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn discriminant(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn cases(&self) -> JsSwitchCaseList {
        support::list(&self.syntax, 5usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 6usize)
    }
}
impl Serialize for JsSwitchStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsSwitchStatementFields {
    pub switch_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub discriminant: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub cases: JsSwitchCaseList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsTemplateChunkElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsTemplateChunkElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsTemplateChunkElementFields {
        JsTemplateChunkElementFields {
            template_chunk_token: self.template_chunk_token(),
        }
    }
    pub fn template_chunk_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsTemplateChunkElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsTemplateChunkElementFields {
    pub template_chunk_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsTemplateElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsTemplateElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsTemplateElementFields {
        JsTemplateElementFields {
            dollar_curly_token: self.dollar_curly_token(),
            expression: self.expression(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn dollar_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsTemplateElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsTemplateElementFields {
    pub dollar_curly_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsTemplateExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsTemplateExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsTemplateExpressionFields {
        JsTemplateExpressionFields {
            tag: self.tag(),
            type_arguments: self.type_arguments(),
            l_tick_token: self.l_tick_token(),
            elements: self.elements(),
            r_tick_token: self.r_tick_token(),
        }
    }
    pub fn tag(&self) -> Option<AnyJsExpression> {
        support::node(&self.syntax, 0usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 1usize)
    }
    pub fn l_tick_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn elements(&self) -> JsTemplateElementList {
        support::list(&self.syntax, 3usize)
    }
    pub fn r_tick_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for JsTemplateExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsTemplateExpressionFields {
    pub tag: Option<AnyJsExpression>,
    pub type_arguments: Option<TsTypeArguments>,
    pub l_tick_token: SyntaxResult<SyntaxToken>,
    pub elements: JsTemplateElementList,
    pub r_tick_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsThisExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsThisExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsThisExpressionFields {
        JsThisExpressionFields {
            this_token: self.this_token(),
        }
    }
    pub fn this_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsThisExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsThisExpressionFields {
    pub this_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsThrowStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsThrowStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsThrowStatementFields {
        JsThrowStatementFields {
            throw_token: self.throw_token(),
            argument: self.argument(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn throw_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn argument(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for JsThrowStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsThrowStatementFields {
    pub throw_token: SyntaxResult<SyntaxToken>,
    pub argument: SyntaxResult<AnyJsExpression>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsTryFinallyStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsTryFinallyStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsTryFinallyStatementFields {
        JsTryFinallyStatementFields {
            try_token: self.try_token(),
            body: self.body(),
            catch_clause: self.catch_clause(),
            finally_clause: self.finally_clause(),
        }
    }
    pub fn try_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn body(&self) -> SyntaxResult<JsBlockStatement> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn catch_clause(&self) -> Option<JsCatchClause> {
        support::node(&self.syntax, 2usize)
    }
    pub fn finally_clause(&self) -> SyntaxResult<JsFinallyClause> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for JsTryFinallyStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsTryFinallyStatementFields {
    pub try_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<JsBlockStatement>,
    pub catch_clause: Option<JsCatchClause>,
    pub finally_clause: SyntaxResult<JsFinallyClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsTryStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsTryStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsTryStatementFields {
        JsTryStatementFields {
            try_token: self.try_token(),
            body: self.body(),
            catch_clause: self.catch_clause(),
        }
    }
    pub fn try_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn body(&self) -> SyntaxResult<JsBlockStatement> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn catch_clause(&self) -> SyntaxResult<JsCatchClause> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsTryStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsTryStatementFields {
    pub try_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<JsBlockStatement>,
    pub catch_clause: SyntaxResult<JsCatchClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsUnaryExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsUnaryExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsUnaryExpressionFields {
        JsUnaryExpressionFields {
            operator_token: self.operator_token(),
            argument: self.argument(),
        }
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn argument(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsUnaryExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsUnaryExpressionFields {
    pub operator_token: SyntaxResult<SyntaxToken>,
    pub argument: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsVariableDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl JsVariableDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsVariableDeclarationFields {
        JsVariableDeclarationFields {
            await_token: self.await_token(),
            kind: self.kind(),
            declarators: self.declarators(),
        }
    }
    pub fn await_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn kind(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn declarators(&self) -> JsVariableDeclaratorList {
        support::list(&self.syntax, 2usize)
    }
}
impl Serialize for JsVariableDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsVariableDeclarationFields {
    pub await_token: Option<SyntaxToken>,
    pub kind: SyntaxResult<SyntaxToken>,
    pub declarators: JsVariableDeclaratorList,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsVariableDeclarationClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsVariableDeclarationClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsVariableDeclarationClauseFields {
        JsVariableDeclarationClauseFields {
            declaration: self.declaration(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn declaration(&self) -> SyntaxResult<JsVariableDeclaration> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
}
impl Serialize for JsVariableDeclarationClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsVariableDeclarationClauseFields {
    pub declaration: SyntaxResult<JsVariableDeclaration>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsVariableDeclarator {
    pub(crate) syntax: SyntaxNode,
}
impl JsVariableDeclarator {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsVariableDeclaratorFields {
        JsVariableDeclaratorFields {
            id: self.id(),
            variable_annotation: self.variable_annotation(),
            initializer: self.initializer(),
        }
    }
    pub fn id(&self) -> SyntaxResult<AnyJsBindingPattern> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn variable_annotation(&self) -> Option<AnyTsVariableAnnotation> {
        support::node(&self.syntax, 1usize)
    }
    pub fn initializer(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 2usize)
    }
}
impl Serialize for JsVariableDeclarator {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsVariableDeclaratorFields {
    pub id: SyntaxResult<AnyJsBindingPattern>,
    pub variable_annotation: Option<AnyTsVariableAnnotation>,
    pub initializer: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsVariableStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsVariableStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsVariableStatementFields {
        JsVariableStatementFields {
            declaration: self.declaration(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn declaration(&self) -> SyntaxResult<JsVariableDeclaration> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
}
impl Serialize for JsVariableStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsVariableStatementFields {
    pub declaration: SyntaxResult<JsVariableDeclaration>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsWhileStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsWhileStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsWhileStatementFields {
        JsWhileStatementFields {
            while_token: self.while_token(),
            l_paren_token: self.l_paren_token(),
            test: self.test(),
            r_paren_token: self.r_paren_token(),
            body: self.body(),
        }
    }
    pub fn while_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn test(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 4usize)
    }
}
impl Serialize for JsWhileStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsWhileStatementFields {
    pub while_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub test: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsWithStatement {
    pub(crate) syntax: SyntaxNode,
}
impl JsWithStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsWithStatementFields {
        JsWithStatementFields {
            with_token: self.with_token(),
            l_paren_token: self.l_paren_token(),
            object: self.object(),
            r_paren_token: self.r_paren_token(),
            body: self.body(),
        }
    }
    pub fn with_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn object(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn body(&self) -> SyntaxResult<AnyJsStatement> {
        support::required_node(&self.syntax, 4usize)
    }
}
impl Serialize for JsWithStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsWithStatementFields {
    pub with_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub object: SyntaxResult<AnyJsExpression>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<AnyJsStatement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsYieldArgument {
    pub(crate) syntax: SyntaxNode,
}
impl JsYieldArgument {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsYieldArgumentFields {
        JsYieldArgumentFields {
            star_token: self.star_token(),
            expression: self.expression(),
        }
    }
    pub fn star_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsYieldArgument {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsYieldArgumentFields {
    pub star_token: Option<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsYieldExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsYieldExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsYieldExpressionFields {
        JsYieldExpressionFields {
            yield_token: self.yield_token(),
            argument: self.argument(),
        }
    }
    pub fn yield_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn argument(&self) -> Option<JsYieldArgument> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for JsYieldExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsYieldExpressionFields {
    pub yield_token: SyntaxResult<SyntaxToken>,
    pub argument: Option<JsYieldArgument>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxAttribute {
    pub(crate) syntax: SyntaxNode,
}
impl JsxAttribute {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxAttributeFields {
        JsxAttributeFields {
            name: self.name(),
            initializer: self.initializer(),
        }
    }
    pub fn name(&self) -> SyntaxResult<AnyJsxAttributeName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn initializer(&self) -> Option<JsxAttributeInitializerClause> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for JsxAttribute {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxAttributeFields {
    pub name: SyntaxResult<AnyJsxAttributeName>,
    pub initializer: Option<JsxAttributeInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxAttributeInitializerClause {
    pub(crate) syntax: SyntaxNode,
}
impl JsxAttributeInitializerClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxAttributeInitializerClauseFields {
        JsxAttributeInitializerClauseFields {
            eq_token: self.eq_token(),
            value: self.value(),
        }
    }
    pub fn eq_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn value(&self) -> SyntaxResult<AnyJsxAttributeValue> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for JsxAttributeInitializerClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxAttributeInitializerClauseFields {
    pub eq_token: SyntaxResult<SyntaxToken>,
    pub value: SyntaxResult<AnyJsxAttributeValue>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxClosingElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsxClosingElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxClosingElementFields {
        JsxClosingElementFields {
            l_angle_token: self.l_angle_token(),
            slash_token: self.slash_token(),
            name: self.name(),
            r_angle_token: self.r_angle_token(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn slash_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsxElementName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsxClosingElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxClosingElementFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub slash_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsxElementName>,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxClosingFragment {
    pub(crate) syntax: SyntaxNode,
}
impl JsxClosingFragment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxClosingFragmentFields {
        JsxClosingFragmentFields {
            l_angle_token: self.l_angle_token(),
            slash_token: self.slash_token(),
            r_angle_token: self.r_angle_token(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn slash_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsxClosingFragment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxClosingFragmentFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub slash_token: SyntaxResult<SyntaxToken>,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsxElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxElementFields {
        JsxElementFields {
            opening_element: self.opening_element(),
            children: self.children(),
            closing_element: self.closing_element(),
        }
    }
    pub fn opening_element(&self) -> SyntaxResult<JsxOpeningElement> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn children(&self) -> JsxChildList {
        support::list(&self.syntax, 1usize)
    }
    pub fn closing_element(&self) -> SyntaxResult<JsxClosingElement> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsxElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxElementFields {
    pub opening_element: SyntaxResult<JsxOpeningElement>,
    pub children: JsxChildList,
    pub closing_element: SyntaxResult<JsxClosingElement>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxExpressionAttributeValue {
    pub(crate) syntax: SyntaxNode,
}
impl JsxExpressionAttributeValue {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxExpressionAttributeValueFields {
        JsxExpressionAttributeValueFields {
            l_curly_token: self.l_curly_token(),
            expression: self.expression(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsxExpressionAttributeValue {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxExpressionAttributeValueFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxExpressionChild {
    pub(crate) syntax: SyntaxNode,
}
impl JsxExpressionChild {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxExpressionChildFields {
        JsxExpressionChildFields {
            l_curly_token: self.l_curly_token(),
            expression: self.expression(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> Option<AnyJsExpression> {
        support::node(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for JsxExpressionChild {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxExpressionChildFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub expression: Option<AnyJsExpression>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxFragment {
    pub(crate) syntax: SyntaxNode,
}
impl JsxFragment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxFragmentFields {
        JsxFragmentFields {
            opening_fragment: self.opening_fragment(),
            children: self.children(),
            closing_fragment: self.closing_fragment(),
        }
    }
    pub fn opening_fragment(&self) -> SyntaxResult<JsxOpeningFragment> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn children(&self) -> JsxChildList {
        support::list(&self.syntax, 1usize)
    }
    pub fn closing_fragment(&self) -> SyntaxResult<JsxClosingFragment> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsxFragment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxFragmentFields {
    pub opening_fragment: SyntaxResult<JsxOpeningFragment>,
    pub children: JsxChildList,
    pub closing_fragment: SyntaxResult<JsxClosingFragment>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxMemberName {
    pub(crate) syntax: SyntaxNode,
}
impl JsxMemberName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxMemberNameFields {
        JsxMemberNameFields {
            object: self.object(),
            dot_token: self.dot_token(),
            member: self.member(),
        }
    }
    pub fn object(&self) -> SyntaxResult<AnyJsxObjectName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn dot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn member(&self) -> SyntaxResult<JsName> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsxMemberName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxMemberNameFields {
    pub object: SyntaxResult<AnyJsxObjectName>,
    pub dot_token: SyntaxResult<SyntaxToken>,
    pub member: SyntaxResult<JsName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxName {
    pub(crate) syntax: SyntaxNode,
}
impl JsxName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxNameFields {
        JsxNameFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsxName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxNameFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxNamespaceName {
    pub(crate) syntax: SyntaxNode,
}
impl JsxNamespaceName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxNamespaceNameFields {
        JsxNamespaceNameFields {
            namespace: self.namespace(),
            colon_token: self.colon_token(),
            name: self.name(),
        }
    }
    pub fn namespace(&self) -> SyntaxResult<JsxName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<JsxName> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for JsxNamespaceName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxNamespaceNameFields {
    pub namespace: SyntaxResult<JsxName>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<JsxName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxOpeningElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsxOpeningElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxOpeningElementFields {
        JsxOpeningElementFields {
            l_angle_token: self.l_angle_token(),
            name: self.name(),
            type_arguments: self.type_arguments(),
            attributes: self.attributes(),
            r_angle_token: self.r_angle_token(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsxElementName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 2usize)
    }
    pub fn attributes(&self) -> JsxAttributeList {
        support::list(&self.syntax, 3usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for JsxOpeningElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxOpeningElementFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsxElementName>,
    pub type_arguments: Option<TsTypeArguments>,
    pub attributes: JsxAttributeList,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxOpeningFragment {
    pub(crate) syntax: SyntaxNode,
}
impl JsxOpeningFragment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxOpeningFragmentFields {
        JsxOpeningFragmentFields {
            l_angle_token: self.l_angle_token(),
            r_angle_token: self.r_angle_token(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for JsxOpeningFragment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxOpeningFragmentFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxReferenceIdentifier {
    pub(crate) syntax: SyntaxNode,
}
impl JsxReferenceIdentifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxReferenceIdentifierFields {
        JsxReferenceIdentifierFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsxReferenceIdentifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxReferenceIdentifierFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxSelfClosingElement {
    pub(crate) syntax: SyntaxNode,
}
impl JsxSelfClosingElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxSelfClosingElementFields {
        JsxSelfClosingElementFields {
            l_angle_token: self.l_angle_token(),
            name: self.name(),
            type_arguments: self.type_arguments(),
            attributes: self.attributes(),
            slash_token: self.slash_token(),
            r_angle_token: self.r_angle_token(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsxElementName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 2usize)
    }
    pub fn attributes(&self) -> JsxAttributeList {
        support::list(&self.syntax, 3usize)
    }
    pub fn slash_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
}
impl Serialize for JsxSelfClosingElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxSelfClosingElementFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsxElementName>,
    pub type_arguments: Option<TsTypeArguments>,
    pub attributes: JsxAttributeList,
    pub slash_token: SyntaxResult<SyntaxToken>,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxSpreadAttribute {
    pub(crate) syntax: SyntaxNode,
}
impl JsxSpreadAttribute {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxSpreadAttributeFields {
        JsxSpreadAttributeFields {
            l_curly_token: self.l_curly_token(),
            dotdotdot_token: self.dotdotdot_token(),
            argument: self.argument(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn argument(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsxSpreadAttribute {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxSpreadAttributeFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub argument: SyntaxResult<AnyJsExpression>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxSpreadChild {
    pub(crate) syntax: SyntaxNode,
}
impl JsxSpreadChild {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxSpreadChildFields {
        JsxSpreadChildFields {
            l_curly_token: self.l_curly_token(),
            dotdotdot_token: self.dotdotdot_token(),
            expression: self.expression(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for JsxSpreadChild {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxSpreadChildFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxString {
    pub(crate) syntax: SyntaxNode,
}
impl JsxString {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxStringFields {
        JsxStringFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsxString {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxStringFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxTagExpression {
    pub(crate) syntax: SyntaxNode,
}
impl JsxTagExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxTagExpressionFields {
        JsxTagExpressionFields { tag: self.tag() }
    }
    pub fn tag(&self) -> SyntaxResult<AnyJsxTag> {
        support::required_node(&self.syntax, 0usize)
    }
}
impl Serialize for JsxTagExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxTagExpressionFields {
    pub tag: SyntaxResult<AnyJsxTag>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct JsxText {
    pub(crate) syntax: SyntaxNode,
}
impl JsxText {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> JsxTextFields {
        JsxTextFields {
            value_token: self.value_token(),
        }
    }
    pub fn value_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for JsxText {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct JsxTextFields {
    pub value_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsAbstractModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsAbstractModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsAbstractModifierFields {
        TsAbstractModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsAbstractModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsAbstractModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsAccessibilityModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsAccessibilityModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsAccessibilityModifierFields {
        TsAccessibilityModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsAccessibilityModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsAccessibilityModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsAnyType {
    pub(crate) syntax: SyntaxNode,
}
impl TsAnyType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsAnyTypeFields {
        TsAnyTypeFields {
            any_token: self.any_token(),
        }
    }
    pub fn any_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsAnyType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsAnyTypeFields {
    pub any_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsArrayType {
    pub(crate) syntax: SyntaxNode,
}
impl TsArrayType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsArrayTypeFields {
        TsArrayTypeFields {
            element_type: self.element_type(),
            l_brack_token: self.l_brack_token(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn element_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsArrayType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsArrayTypeFields {
    pub element_type: SyntaxResult<AnyTsType>,
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsAsAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl TsAsAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsAsAssignmentFields {
        TsAsAssignmentFields {
            assignment: self.assignment(),
            as_token: self.as_token(),
            ty: self.ty(),
        }
    }
    pub fn assignment(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsAsAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsAsAssignmentFields {
    pub assignment: SyntaxResult<AnyJsAssignment>,
    pub as_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsAsExpression {
    pub(crate) syntax: SyntaxNode,
}
impl TsAsExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsAsExpressionFields {
        TsAsExpressionFields {
            expression: self.expression(),
            as_token: self.as_token(),
            ty: self.ty(),
        }
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsAsExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsAsExpressionFields {
    pub expression: SyntaxResult<AnyJsExpression>,
    pub as_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsAssertsCondition {
    pub(crate) syntax: SyntaxNode,
}
impl TsAssertsCondition {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsAssertsConditionFields {
        TsAssertsConditionFields {
            is_token: self.is_token(),
            ty: self.ty(),
        }
    }
    pub fn is_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsAssertsCondition {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsAssertsConditionFields {
    pub is_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsAssertsReturnType {
    pub(crate) syntax: SyntaxNode,
}
impl TsAssertsReturnType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsAssertsReturnTypeFields {
        TsAssertsReturnTypeFields {
            asserts_token: self.asserts_token(),
            parameter_name: self.parameter_name(),
            predicate: self.predicate(),
        }
    }
    pub fn asserts_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn parameter_name(&self) -> SyntaxResult<AnyTsTypePredicateParameterName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn predicate(&self) -> Option<TsAssertsCondition> {
        support::node(&self.syntax, 2usize)
    }
}
impl Serialize for TsAssertsReturnType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsAssertsReturnTypeFields {
    pub asserts_token: SyntaxResult<SyntaxToken>,
    pub parameter_name: SyntaxResult<AnyTsTypePredicateParameterName>,
    pub predicate: Option<TsAssertsCondition>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsBigintLiteralType {
    pub(crate) syntax: SyntaxNode,
}
impl TsBigintLiteralType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsBigintLiteralTypeFields {
        TsBigintLiteralTypeFields {
            minus_token: self.minus_token(),
            literal_token: self.literal_token(),
        }
    }
    pub fn minus_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn literal_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for TsBigintLiteralType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsBigintLiteralTypeFields {
    pub minus_token: Option<SyntaxToken>,
    pub literal_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsBigintType {
    pub(crate) syntax: SyntaxNode,
}
impl TsBigintType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsBigintTypeFields {
        TsBigintTypeFields {
            bigint_token: self.bigint_token(),
        }
    }
    pub fn bigint_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsBigintType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsBigintTypeFields {
    pub bigint_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsBooleanLiteralType {
    pub(crate) syntax: SyntaxNode,
}
impl TsBooleanLiteralType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsBooleanLiteralTypeFields {
        TsBooleanLiteralTypeFields {
            literal: self.literal(),
        }
    }
    pub fn literal(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsBooleanLiteralType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsBooleanLiteralTypeFields {
    pub literal: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsBooleanType {
    pub(crate) syntax: SyntaxNode,
}
impl TsBooleanType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsBooleanTypeFields {
        TsBooleanTypeFields {
            boolean_token: self.boolean_token(),
        }
    }
    pub fn boolean_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsBooleanType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsBooleanTypeFields {
    pub boolean_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsCallSignatureTypeMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsCallSignatureTypeMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsCallSignatureTypeMemberFields {
        TsCallSignatureTypeMemberFields {
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            separator_token: self.separator_token(),
        }
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 0usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 2usize)
    }
    pub fn separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 3usize)
    }
}
impl Serialize for TsCallSignatureTypeMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsCallSignatureTypeMemberFields {
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub separator_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsConditionalType {
    pub(crate) syntax: SyntaxNode,
}
impl TsConditionalType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsConditionalTypeFields {
        TsConditionalTypeFields {
            check_type: self.check_type(),
            extends_token: self.extends_token(),
            extends_type: self.extends_type(),
            question_mark_token: self.question_mark_token(),
            true_type: self.true_type(),
            colon_token: self.colon_token(),
            false_type: self.false_type(),
        }
    }
    pub fn check_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn extends_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn extends_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn question_mark_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn true_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
    pub fn false_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 6usize)
    }
}
impl Serialize for TsConditionalType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsConditionalTypeFields {
    pub check_type: SyntaxResult<AnyTsType>,
    pub extends_token: SyntaxResult<SyntaxToken>,
    pub extends_type: SyntaxResult<AnyTsType>,
    pub question_mark_token: SyntaxResult<SyntaxToken>,
    pub true_type: SyntaxResult<AnyTsType>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub false_type: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsConstModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsConstModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsConstModifierFields {
        TsConstModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsConstModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsConstModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsConstructSignatureTypeMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsConstructSignatureTypeMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsConstructSignatureTypeMemberFields {
        TsConstructSignatureTypeMemberFields {
            new_token: self.new_token(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            type_annotation: self.type_annotation(),
            separator_token: self.separator_token(),
        }
    }
    pub fn new_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 1usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 3usize)
    }
    pub fn separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
}
impl Serialize for TsConstructSignatureTypeMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsConstructSignatureTypeMemberFields {
    pub new_token: SyntaxResult<SyntaxToken>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub type_annotation: Option<TsTypeAnnotation>,
    pub separator_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsConstructorSignatureClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsConstructorSignatureClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsConstructorSignatureClassMemberFields {
        TsConstructorSignatureClassMemberFields {
            modifiers: self.modifiers(),
            name: self.name(),
            parameters: self.parameters(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> JsConstructorModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<JsLiteralMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsConstructorParameters> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 3usize)
    }
}
impl Serialize for TsConstructorSignatureClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsConstructorSignatureClassMemberFields {
    pub modifiers: JsConstructorModifierList,
    pub name: SyntaxResult<JsLiteralMemberName>,
    pub parameters: SyntaxResult<JsConstructorParameters>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsConstructorType {
    pub(crate) syntax: SyntaxNode,
}
impl TsConstructorType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsConstructorTypeFields {
        TsConstructorTypeFields {
            abstract_token: self.abstract_token(),
            new_token: self.new_token(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            fat_arrow_token: self.fat_arrow_token(),
            return_type: self.return_type(),
        }
    }
    pub fn abstract_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn new_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 2usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn fat_arrow_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn return_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 5usize)
    }
}
impl Serialize for TsConstructorType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsConstructorTypeFields {
    pub abstract_token: Option<SyntaxToken>,
    pub new_token: SyntaxResult<SyntaxToken>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub fat_arrow_token: SyntaxResult<SyntaxToken>,
    pub return_type: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDeclarationModule {
    pub(crate) syntax: SyntaxNode,
}
impl TsDeclarationModule {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDeclarationModuleFields {
        TsDeclarationModuleFields {
            bom_token: self.bom_token(),
            interpreter_token: self.interpreter_token(),
            directives: self.directives(),
            items: self.items(),
            eof_token: self.eof_token(),
        }
    }
    pub fn bom_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn interpreter_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn directives(&self) -> JsDirectiveList {
        support::list(&self.syntax, 2usize)
    }
    pub fn items(&self) -> JsModuleItemList {
        support::list(&self.syntax, 3usize)
    }
    pub fn eof_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for TsDeclarationModule {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDeclarationModuleFields {
    pub bom_token: Option<SyntaxToken>,
    pub interpreter_token: Option<SyntaxToken>,
    pub directives: JsDirectiveList,
    pub items: JsModuleItemList,
    pub eof_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDeclareFunctionDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsDeclareFunctionDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDeclareFunctionDeclarationFields {
        TsDeclareFunctionDeclarationFields {
            async_token: self.async_token(),
            function_token: self.function_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn function_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn id(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 3usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 5usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 6usize)
    }
}
impl Serialize for TsDeclareFunctionDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDeclareFunctionDeclarationFields {
    pub async_token: Option<SyntaxToken>,
    pub function_token: SyntaxResult<SyntaxToken>,
    pub id: SyntaxResult<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDeclareFunctionExportDefaultDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsDeclareFunctionExportDefaultDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDeclareFunctionExportDefaultDeclarationFields {
        TsDeclareFunctionExportDefaultDeclarationFields {
            async_token: self.async_token(),
            function_token: self.function_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn function_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn id(&self) -> Option<AnyJsBinding> {
        support::node(&self.syntax, 2usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 3usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 5usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 6usize)
    }
}
impl Serialize for TsDeclareFunctionExportDefaultDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDeclareFunctionExportDefaultDeclarationFields {
    pub async_token: Option<SyntaxToken>,
    pub function_token: SyntaxResult<SyntaxToken>,
    pub id: Option<AnyJsBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDeclareModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsDeclareModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDeclareModifierFields {
        TsDeclareModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsDeclareModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDeclareModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDeclareStatement {
    pub(crate) syntax: SyntaxNode,
}
impl TsDeclareStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDeclareStatementFields {
        TsDeclareStatementFields {
            declare_token: self.declare_token(),
            declaration: self.declaration(),
        }
    }
    pub fn declare_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn declaration(&self) -> SyntaxResult<AnyJsDeclarationClause> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsDeclareStatement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDeclareStatementFields {
    pub declare_token: SyntaxResult<SyntaxToken>,
    pub declaration: SyntaxResult<AnyJsDeclarationClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDefaultTypeClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsDefaultTypeClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDefaultTypeClauseFields {
        TsDefaultTypeClauseFields {
            eq_token: self.eq_token(),
            ty: self.ty(),
        }
    }
    pub fn eq_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsDefaultTypeClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDefaultTypeClauseFields {
    pub eq_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDefinitePropertyAnnotation {
    pub(crate) syntax: SyntaxNode,
}
impl TsDefinitePropertyAnnotation {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDefinitePropertyAnnotationFields {
        TsDefinitePropertyAnnotationFields {
            excl_token: self.excl_token(),
            type_annotation: self.type_annotation(),
        }
    }
    pub fn excl_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn type_annotation(&self) -> SyntaxResult<TsTypeAnnotation> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsDefinitePropertyAnnotation {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDefinitePropertyAnnotationFields {
    pub excl_token: SyntaxResult<SyntaxToken>,
    pub type_annotation: SyntaxResult<TsTypeAnnotation>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsDefiniteVariableAnnotation {
    pub(crate) syntax: SyntaxNode,
}
impl TsDefiniteVariableAnnotation {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsDefiniteVariableAnnotationFields {
        TsDefiniteVariableAnnotationFields {
            excl_token: self.excl_token(),
            type_annotation: self.type_annotation(),
        }
    }
    pub fn excl_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn type_annotation(&self) -> SyntaxResult<TsTypeAnnotation> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsDefiniteVariableAnnotation {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsDefiniteVariableAnnotationFields {
    pub excl_token: SyntaxResult<SyntaxToken>,
    pub type_annotation: SyntaxResult<TsTypeAnnotation>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsEmptyExternalModuleDeclarationBody {
    pub(crate) syntax: SyntaxNode,
}
impl TsEmptyExternalModuleDeclarationBody {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsEmptyExternalModuleDeclarationBodyFields {
        TsEmptyExternalModuleDeclarationBodyFields {
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn semicolon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsEmptyExternalModuleDeclarationBody {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsEmptyExternalModuleDeclarationBodyFields {
    pub semicolon_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsEnumDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsEnumDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsEnumDeclarationFields {
        TsEnumDeclarationFields {
            const_token: self.const_token(),
            enum_token: self.enum_token(),
            id: self.id(),
            l_curly_token: self.l_curly_token(),
            members: self.members(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn const_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn enum_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn id(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn members(&self) -> TsEnumMemberList {
        support::list(&self.syntax, 4usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
}
impl Serialize for TsEnumDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsEnumDeclarationFields {
    pub const_token: Option<SyntaxToken>,
    pub enum_token: SyntaxResult<SyntaxToken>,
    pub id: SyntaxResult<AnyJsBinding>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub members: TsEnumMemberList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsEnumMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsEnumMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsEnumMemberFields {
        TsEnumMemberFields {
            name: self.name(),
            initializer: self.initializer(),
        }
    }
    pub fn name(&self) -> SyntaxResult<AnyTsEnumMemberName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn initializer(&self) -> Option<JsInitializerClause> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for TsEnumMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsEnumMemberFields {
    pub name: SyntaxResult<AnyTsEnumMemberName>,
    pub initializer: Option<JsInitializerClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsExportAsNamespaceClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsExportAsNamespaceClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsExportAsNamespaceClauseFields {
        TsExportAsNamespaceClauseFields {
            as_token: self.as_token(),
            namespace_token: self.namespace_token(),
            name: self.name(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn namespace_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<JsName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 3usize)
    }
}
impl Serialize for TsExportAsNamespaceClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsExportAsNamespaceClauseFields {
    pub as_token: SyntaxResult<SyntaxToken>,
    pub namespace_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<JsName>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsExportAssignmentClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsExportAssignmentClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsExportAssignmentClauseFields {
        TsExportAssignmentClauseFields {
            eq_token: self.eq_token(),
            expression: self.expression(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn eq_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
}
impl Serialize for TsExportAssignmentClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsExportAssignmentClauseFields {
    pub eq_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsExportDeclareClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsExportDeclareClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsExportDeclareClauseFields {
        TsExportDeclareClauseFields {
            declare_token: self.declare_token(),
            declaration: self.declaration(),
        }
    }
    pub fn declare_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn declaration(&self) -> SyntaxResult<AnyJsDeclarationClause> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsExportDeclareClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsExportDeclareClauseFields {
    pub declare_token: SyntaxResult<SyntaxToken>,
    pub declaration: SyntaxResult<AnyJsDeclarationClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsExtendsClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsExtendsClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsExtendsClauseFields {
        TsExtendsClauseFields {
            extends_token: self.extends_token(),
            types: self.types(),
        }
    }
    pub fn extends_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn types(&self) -> TsTypeList {
        support::list(&self.syntax, 1usize)
    }
}
impl Serialize for TsExtendsClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsExtendsClauseFields {
    pub extends_token: SyntaxResult<SyntaxToken>,
    pub types: TsTypeList,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsExternalModuleDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsExternalModuleDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsExternalModuleDeclarationFields {
        TsExternalModuleDeclarationFields {
            module_token: self.module_token(),
            source: self.source(),
            body: self.body(),
        }
    }
    pub fn module_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn body(&self) -> Option<AnyTsExternalModuleDeclarationBody> {
        support::node(&self.syntax, 2usize)
    }
}
impl Serialize for TsExternalModuleDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsExternalModuleDeclarationFields {
    pub module_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub body: Option<AnyTsExternalModuleDeclarationBody>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsExternalModuleReference {
    pub(crate) syntax: SyntaxNode,
}
impl TsExternalModuleReference {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsExternalModuleReferenceFields {
        TsExternalModuleReferenceFields {
            require_token: self.require_token(),
            l_paren_token: self.l_paren_token(),
            source: self.source(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn require_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn source(&self) -> SyntaxResult<AnyJsModuleSource> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for TsExternalModuleReference {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsExternalModuleReferenceFields {
    pub require_token: SyntaxResult<SyntaxToken>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub source: SyntaxResult<AnyJsModuleSource>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsFunctionType {
    pub(crate) syntax: SyntaxNode,
}
impl TsFunctionType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsFunctionTypeFields {
        TsFunctionTypeFields {
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            fat_arrow_token: self.fat_arrow_token(),
            return_type: self.return_type(),
        }
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 0usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn fat_arrow_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn return_type(&self) -> SyntaxResult<AnyTsReturnType> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for TsFunctionType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsFunctionTypeFields {
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub fat_arrow_token: SyntaxResult<SyntaxToken>,
    pub return_type: SyntaxResult<AnyTsReturnType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsGetterSignatureClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsGetterSignatureClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsGetterSignatureClassMemberFields {
        TsGetterSignatureClassMemberFields {
            modifiers: self.modifiers(),
            get_token: self.get_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            r_paren_token: self.r_paren_token(),
            return_type: self.return_type(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> TsMethodSignatureModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn get_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn return_type(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 5usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 6usize)
    }
}
impl Serialize for TsGetterSignatureClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsGetterSignatureClassMemberFields {
    pub modifiers: TsMethodSignatureModifierList,
    pub get_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub return_type: Option<TsTypeAnnotation>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsGetterSignatureTypeMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsGetterSignatureTypeMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsGetterSignatureTypeMemberFields {
        TsGetterSignatureTypeMemberFields {
            get_token: self.get_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            r_paren_token: self.r_paren_token(),
            type_annotation: self.type_annotation(),
            separator_token: self.separator_token(),
        }
    }
    pub fn get_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 4usize)
    }
    pub fn separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
}
impl Serialize for TsGetterSignatureTypeMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsGetterSignatureTypeMemberFields {
    pub get_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub type_annotation: Option<TsTypeAnnotation>,
    pub separator_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsGlobalDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsGlobalDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsGlobalDeclarationFields {
        TsGlobalDeclarationFields {
            global_token: self.global_token(),
            body: self.body(),
        }
    }
    pub fn global_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn body(&self) -> SyntaxResult<TsModuleBlock> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsGlobalDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsGlobalDeclarationFields {
    pub global_token: SyntaxResult<SyntaxToken>,
    pub body: SyntaxResult<TsModuleBlock>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsIdentifierBinding {
    pub(crate) syntax: SyntaxNode,
}
impl TsIdentifierBinding {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsIdentifierBindingFields {
        TsIdentifierBindingFields {
            name_token: self.name_token(),
        }
    }
    pub fn name_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsIdentifierBinding {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsIdentifierBindingFields {
    pub name_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsImplementsClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsImplementsClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsImplementsClauseFields {
        TsImplementsClauseFields {
            implements_token: self.implements_token(),
            types: self.types(),
        }
    }
    pub fn implements_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn types(&self) -> TsTypeList {
        support::list(&self.syntax, 1usize)
    }
}
impl Serialize for TsImplementsClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsImplementsClauseFields {
    pub implements_token: SyntaxResult<SyntaxToken>,
    pub types: TsTypeList,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsImportEqualsDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsImportEqualsDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsImportEqualsDeclarationFields {
        TsImportEqualsDeclarationFields {
            import_token: self.import_token(),
            type_token: self.type_token(),
            id: self.id(),
            eq_token: self.eq_token(),
            module_reference: self.module_reference(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn import_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn type_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn id(&self) -> SyntaxResult<AnyJsBinding> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn eq_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn module_reference(&self) -> SyntaxResult<AnyTsModuleReference> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
}
impl Serialize for TsImportEqualsDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsImportEqualsDeclarationFields {
    pub import_token: SyntaxResult<SyntaxToken>,
    pub type_token: Option<SyntaxToken>,
    pub id: SyntaxResult<AnyJsBinding>,
    pub eq_token: SyntaxResult<SyntaxToken>,
    pub module_reference: SyntaxResult<AnyTsModuleReference>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsImportType {
    pub(crate) syntax: SyntaxNode,
}
impl TsImportType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsImportTypeFields {
        TsImportTypeFields {
            typeof_token: self.typeof_token(),
            import_token: self.import_token(),
            arguments: self.arguments(),
            qualifier_clause: self.qualifier_clause(),
            type_arguments: self.type_arguments(),
        }
    }
    pub fn typeof_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn import_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn arguments(&self) -> SyntaxResult<TsImportTypeArguments> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn qualifier_clause(&self) -> Option<TsImportTypeQualifier> {
        support::node(&self.syntax, 3usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 4usize)
    }
}
impl Serialize for TsImportType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsImportTypeFields {
    pub typeof_token: Option<SyntaxToken>,
    pub import_token: SyntaxResult<SyntaxToken>,
    pub arguments: SyntaxResult<TsImportTypeArguments>,
    pub qualifier_clause: Option<TsImportTypeQualifier>,
    pub type_arguments: Option<TsTypeArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsImportTypeArguments {
    pub(crate) syntax: SyntaxNode,
}
impl TsImportTypeArguments {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsImportTypeArgumentsFields {
        TsImportTypeArgumentsFields {
            l_paren_token: self.l_paren_token(),
            argument: self.argument(),
            comma_token: self.comma_token(),
            ts_import_type_assertion_block: self.ts_import_type_assertion_block(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn argument(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn comma_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn ts_import_type_assertion_block(&self) -> Option<TsImportTypeAssertionBlock> {
        support::node(&self.syntax, 3usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for TsImportTypeArguments {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsImportTypeArgumentsFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub argument: SyntaxResult<AnyTsType>,
    pub comma_token: Option<SyntaxToken>,
    pub ts_import_type_assertion_block: Option<TsImportTypeAssertionBlock>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsImportTypeAssertion {
    pub(crate) syntax: SyntaxNode,
}
impl TsImportTypeAssertion {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsImportTypeAssertionFields {
        TsImportTypeAssertionFields {
            with_token: self.with_token(),
            colon_token: self.colon_token(),
            l_curly_token: self.l_curly_token(),
            assertions: self.assertions(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn with_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn assertions(&self) -> JsImportAssertionEntryList {
        support::list(&self.syntax, 3usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
}
impl Serialize for TsImportTypeAssertion {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsImportTypeAssertionFields {
    pub with_token: SyntaxResult<SyntaxToken>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub assertions: JsImportAssertionEntryList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsImportTypeAssertionBlock {
    pub(crate) syntax: SyntaxNode,
}
impl TsImportTypeAssertionBlock {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsImportTypeAssertionBlockFields {
        TsImportTypeAssertionBlockFields {
            l_curly_token: self.l_curly_token(),
            type_assertion: self.type_assertion(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn type_assertion(&self) -> SyntaxResult<TsImportTypeAssertion> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsImportTypeAssertionBlock {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsImportTypeAssertionBlockFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub type_assertion: SyntaxResult<TsImportTypeAssertion>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsImportTypeQualifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsImportTypeQualifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsImportTypeQualifierFields {
        TsImportTypeQualifierFields {
            dot_token: self.dot_token(),
            right: self.right(),
        }
    }
    pub fn dot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn right(&self) -> SyntaxResult<AnyTsName> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsImportTypeQualifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsImportTypeQualifierFields {
    pub dot_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<AnyTsName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsInModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsInModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsInModifierFields {
        TsInModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsInModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsInModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsIndexSignatureClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsIndexSignatureClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsIndexSignatureClassMemberFields {
        TsIndexSignatureClassMemberFields {
            modifiers: self.modifiers(),
            l_brack_token: self.l_brack_token(),
            parameter: self.parameter(),
            r_brack_token: self.r_brack_token(),
            type_annotation: self.type_annotation(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> TsIndexSignatureModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn parameter(&self) -> SyntaxResult<TsIndexSignatureParameter> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn type_annotation(&self) -> SyntaxResult<TsTypeAnnotation> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
}
impl Serialize for TsIndexSignatureClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsIndexSignatureClassMemberFields {
    pub modifiers: TsIndexSignatureModifierList,
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub parameter: SyntaxResult<TsIndexSignatureParameter>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
    pub type_annotation: SyntaxResult<TsTypeAnnotation>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsIndexSignatureParameter {
    pub(crate) syntax: SyntaxNode,
}
impl TsIndexSignatureParameter {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsIndexSignatureParameterFields {
        TsIndexSignatureParameterFields {
            binding: self.binding(),
            type_annotation: self.type_annotation(),
        }
    }
    pub fn binding(&self) -> SyntaxResult<JsIdentifierBinding> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn type_annotation(&self) -> SyntaxResult<TsTypeAnnotation> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsIndexSignatureParameter {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsIndexSignatureParameterFields {
    pub binding: SyntaxResult<JsIdentifierBinding>,
    pub type_annotation: SyntaxResult<TsTypeAnnotation>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsIndexSignatureTypeMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsIndexSignatureTypeMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsIndexSignatureTypeMemberFields {
        TsIndexSignatureTypeMemberFields {
            readonly_token: self.readonly_token(),
            l_brack_token: self.l_brack_token(),
            parameter: self.parameter(),
            r_brack_token: self.r_brack_token(),
            type_annotation: self.type_annotation(),
            separator_token: self.separator_token(),
        }
    }
    pub fn readonly_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn parameter(&self) -> SyntaxResult<TsIndexSignatureParameter> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn type_annotation(&self) -> SyntaxResult<TsTypeAnnotation> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
}
impl Serialize for TsIndexSignatureTypeMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsIndexSignatureTypeMemberFields {
    pub readonly_token: Option<SyntaxToken>,
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub parameter: SyntaxResult<TsIndexSignatureParameter>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
    pub type_annotation: SyntaxResult<TsTypeAnnotation>,
    pub separator_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsIndexedAccessType {
    pub(crate) syntax: SyntaxNode,
}
impl TsIndexedAccessType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsIndexedAccessTypeFields {
        TsIndexedAccessTypeFields {
            object_type: self.object_type(),
            l_brack_token: self.l_brack_token(),
            index_type: self.index_type(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn object_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn index_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
}
impl Serialize for TsIndexedAccessType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsIndexedAccessTypeFields {
    pub object_type: SyntaxResult<AnyTsType>,
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub index_type: SyntaxResult<AnyTsType>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsInferType {
    pub(crate) syntax: SyntaxNode,
}
impl TsInferType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsInferTypeFields {
        TsInferTypeFields {
            infer_token: self.infer_token(),
            name: self.name(),
            constraint: self.constraint(),
        }
    }
    pub fn infer_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<TsTypeParameterName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn constraint(&self) -> Option<TsTypeConstraintClause> {
        support::node(&self.syntax, 2usize)
    }
}
impl Serialize for TsInferType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsInferTypeFields {
    pub infer_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<TsTypeParameterName>,
    pub constraint: Option<TsTypeConstraintClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsInitializedPropertySignatureClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsInitializedPropertySignatureClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsInitializedPropertySignatureClassMemberFields {
        TsInitializedPropertySignatureClassMemberFields {
            modifiers: self.modifiers(),
            name: self.name(),
            question_mark_token: self.question_mark_token(),
            value: self.value(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> TsPropertySignatureModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn question_mark_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn value(&self) -> SyntaxResult<JsInitializerClause> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
}
impl Serialize for TsInitializedPropertySignatureClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsInitializedPropertySignatureClassMemberFields {
    pub modifiers: TsPropertySignatureModifierList,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub question_mark_token: Option<SyntaxToken>,
    pub value: SyntaxResult<JsInitializerClause>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsInstantiationExpression {
    pub(crate) syntax: SyntaxNode,
}
impl TsInstantiationExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsInstantiationExpressionFields {
        TsInstantiationExpressionFields {
            expression: self.expression(),
            arguments: self.arguments(),
        }
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn arguments(&self) -> SyntaxResult<TsTypeArguments> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsInstantiationExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsInstantiationExpressionFields {
    pub expression: SyntaxResult<AnyJsExpression>,
    pub arguments: SyntaxResult<TsTypeArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsInterfaceDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsInterfaceDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsInterfaceDeclarationFields {
        TsInterfaceDeclarationFields {
            interface_token: self.interface_token(),
            id: self.id(),
            type_parameters: self.type_parameters(),
            extends_clause: self.extends_clause(),
            l_curly_token: self.l_curly_token(),
            members: self.members(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn interface_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn id(&self) -> SyntaxResult<AnyTsIdentifierBinding> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 2usize)
    }
    pub fn extends_clause(&self) -> Option<TsExtendsClause> {
        support::node(&self.syntax, 3usize)
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn members(&self) -> TsTypeMemberList {
        support::list(&self.syntax, 5usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 6usize)
    }
}
impl Serialize for TsInterfaceDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsInterfaceDeclarationFields {
    pub interface_token: SyntaxResult<SyntaxToken>,
    pub id: SyntaxResult<AnyTsIdentifierBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub extends_clause: Option<TsExtendsClause>,
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub members: TsTypeMemberList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsIntersectionType {
    pub(crate) syntax: SyntaxNode,
}
impl TsIntersectionType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsIntersectionTypeFields {
        TsIntersectionTypeFields {
            leading_separator_token: self.leading_separator_token(),
            types: self.types(),
        }
    }
    pub fn leading_separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn types(&self) -> TsIntersectionTypeElementList {
        support::list(&self.syntax, 1usize)
    }
}
impl Serialize for TsIntersectionType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsIntersectionTypeFields {
    pub leading_separator_token: Option<SyntaxToken>,
    pub types: TsIntersectionTypeElementList,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsLiteralEnumMemberName {
    pub(crate) syntax: SyntaxNode,
}
impl TsLiteralEnumMemberName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsLiteralEnumMemberNameFields {
        TsLiteralEnumMemberNameFields {
            value: self.value(),
        }
    }
    pub fn value(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsLiteralEnumMemberName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsLiteralEnumMemberNameFields {
    pub value: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsMappedType {
    pub(crate) syntax: SyntaxNode,
}
impl TsMappedType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsMappedTypeFields {
        TsMappedTypeFields {
            l_curly_token: self.l_curly_token(),
            readonly_modifier: self.readonly_modifier(),
            l_brack_token: self.l_brack_token(),
            property_name: self.property_name(),
            in_token: self.in_token(),
            keys_type: self.keys_type(),
            as_clause: self.as_clause(),
            r_brack_token: self.r_brack_token(),
            optional_modifier: self.optional_modifier(),
            mapped_type: self.mapped_type(),
            semicolon_token: self.semicolon_token(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn readonly_modifier(&self) -> Option<TsMappedTypeReadonlyModifierClause> {
        support::node(&self.syntax, 1usize)
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn property_name(&self) -> SyntaxResult<TsTypeParameterName> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn in_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 4usize)
    }
    pub fn keys_type(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 5usize)
    }
    pub fn as_clause(&self) -> Option<TsMappedTypeAsClause> {
        support::node(&self.syntax, 6usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 7usize)
    }
    pub fn optional_modifier(&self) -> Option<TsMappedTypeOptionalModifierClause> {
        support::node(&self.syntax, 8usize)
    }
    pub fn mapped_type(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 9usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 10usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 11usize)
    }
}
impl Serialize for TsMappedType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsMappedTypeFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub readonly_modifier: Option<TsMappedTypeReadonlyModifierClause>,
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub property_name: SyntaxResult<TsTypeParameterName>,
    pub in_token: SyntaxResult<SyntaxToken>,
    pub keys_type: SyntaxResult<AnyTsType>,
    pub as_clause: Option<TsMappedTypeAsClause>,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
    pub optional_modifier: Option<TsMappedTypeOptionalModifierClause>,
    pub mapped_type: Option<TsTypeAnnotation>,
    pub semicolon_token: Option<SyntaxToken>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsMappedTypeAsClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsMappedTypeAsClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsMappedTypeAsClauseFields {
        TsMappedTypeAsClauseFields {
            as_token: self.as_token(),
            ty: self.ty(),
        }
    }
    pub fn as_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsMappedTypeAsClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsMappedTypeAsClauseFields {
    pub as_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsMappedTypeOptionalModifierClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsMappedTypeOptionalModifierClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsMappedTypeOptionalModifierClauseFields {
        TsMappedTypeOptionalModifierClauseFields {
            operator_token: self.operator_token(),
            question_mark_token: self.question_mark_token(),
        }
    }
    pub fn operator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn question_mark_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for TsMappedTypeOptionalModifierClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsMappedTypeOptionalModifierClauseFields {
    pub operator_token: Option<SyntaxToken>,
    pub question_mark_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsMappedTypeReadonlyModifierClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsMappedTypeReadonlyModifierClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsMappedTypeReadonlyModifierClauseFields {
        TsMappedTypeReadonlyModifierClauseFields {
            operator_token: self.operator_token(),
            readonly_token: self.readonly_token(),
        }
    }
    pub fn operator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn readonly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for TsMappedTypeReadonlyModifierClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsMappedTypeReadonlyModifierClauseFields {
    pub operator_token: Option<SyntaxToken>,
    pub readonly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsMethodSignatureClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsMethodSignatureClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsMethodSignatureClassMemberFields {
        TsMethodSignatureClassMemberFields {
            modifiers: self.modifiers(),
            async_token: self.async_token(),
            name: self.name(),
            question_mark_token: self.question_mark_token(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> TsMethodSignatureModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn async_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn question_mark_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 3usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 4usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 5usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 6usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 7usize)
    }
}
impl Serialize for TsMethodSignatureClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsMethodSignatureClassMemberFields {
    pub modifiers: TsMethodSignatureModifierList,
    pub async_token: Option<SyntaxToken>,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub question_mark_token: Option<SyntaxToken>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsMethodSignatureTypeMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsMethodSignatureTypeMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsMethodSignatureTypeMemberFields {
        TsMethodSignatureTypeMemberFields {
            name: self.name(),
            optional_token: self.optional_token(),
            type_parameters: self.type_parameters(),
            parameters: self.parameters(),
            return_type_annotation: self.return_type_annotation(),
            separator_token: self.separator_token(),
        }
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn optional_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 1usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 2usize)
    }
    pub fn parameters(&self) -> SyntaxResult<JsParameters> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn return_type_annotation(&self) -> Option<TsReturnTypeAnnotation> {
        support::node(&self.syntax, 4usize)
    }
    pub fn separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
}
impl Serialize for TsMethodSignatureTypeMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsMethodSignatureTypeMemberFields {
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub optional_token: Option<SyntaxToken>,
    pub type_parameters: Option<TsTypeParameters>,
    pub parameters: SyntaxResult<JsParameters>,
    pub return_type_annotation: Option<TsReturnTypeAnnotation>,
    pub separator_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsModuleBlock {
    pub(crate) syntax: SyntaxNode,
}
impl TsModuleBlock {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsModuleBlockFields {
        TsModuleBlockFields {
            l_curly_token: self.l_curly_token(),
            items: self.items(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn items(&self) -> JsModuleItemList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsModuleBlock {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsModuleBlockFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub items: JsModuleItemList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsModuleDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsModuleDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsModuleDeclarationFields {
        TsModuleDeclarationFields {
            module_or_namespace: self.module_or_namespace(),
            name: self.name(),
            body: self.body(),
        }
    }
    pub fn module_or_namespace(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyTsModuleName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn body(&self) -> SyntaxResult<TsModuleBlock> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsModuleDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsModuleDeclarationFields {
    pub module_or_namespace: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyTsModuleName>,
    pub body: SyntaxResult<TsModuleBlock>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNamedTupleTypeElement {
    pub(crate) syntax: SyntaxNode,
}
impl TsNamedTupleTypeElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNamedTupleTypeElementFields {
        TsNamedTupleTypeElementFields {
            dotdotdot_token: self.dotdotdot_token(),
            name: self.name(),
            question_mark_token: self.question_mark_token(),
            colon_token: self.colon_token(),
            ty: self.ty(),
        }
    }
    pub fn dotdotdot_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<JsName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn question_mark_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 4usize)
    }
}
impl Serialize for TsNamedTupleTypeElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNamedTupleTypeElementFields {
    pub dotdotdot_token: Option<SyntaxToken>,
    pub name: SyntaxResult<JsName>,
    pub question_mark_token: Option<SyntaxToken>,
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNeverType {
    pub(crate) syntax: SyntaxNode,
}
impl TsNeverType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNeverTypeFields {
        TsNeverTypeFields {
            never_token: self.never_token(),
        }
    }
    pub fn never_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsNeverType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNeverTypeFields {
    pub never_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNonNullAssertionAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl TsNonNullAssertionAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNonNullAssertionAssignmentFields {
        TsNonNullAssertionAssignmentFields {
            assignment: self.assignment(),
            excl_token: self.excl_token(),
        }
    }
    pub fn assignment(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn excl_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for TsNonNullAssertionAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNonNullAssertionAssignmentFields {
    pub assignment: SyntaxResult<AnyJsAssignment>,
    pub excl_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNonNullAssertionExpression {
    pub(crate) syntax: SyntaxNode,
}
impl TsNonNullAssertionExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNonNullAssertionExpressionFields {
        TsNonNullAssertionExpressionFields {
            expression: self.expression(),
            excl_token: self.excl_token(),
        }
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn excl_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for TsNonNullAssertionExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNonNullAssertionExpressionFields {
    pub expression: SyntaxResult<AnyJsExpression>,
    pub excl_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNonPrimitiveType {
    pub(crate) syntax: SyntaxNode,
}
impl TsNonPrimitiveType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNonPrimitiveTypeFields {
        TsNonPrimitiveTypeFields {
            object_token: self.object_token(),
        }
    }
    pub fn object_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsNonPrimitiveType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNonPrimitiveTypeFields {
    pub object_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNullLiteralType {
    pub(crate) syntax: SyntaxNode,
}
impl TsNullLiteralType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNullLiteralTypeFields {
        TsNullLiteralTypeFields {
            literal_token: self.literal_token(),
        }
    }
    pub fn literal_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsNullLiteralType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNullLiteralTypeFields {
    pub literal_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNumberLiteralType {
    pub(crate) syntax: SyntaxNode,
}
impl TsNumberLiteralType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNumberLiteralTypeFields {
        TsNumberLiteralTypeFields {
            minus_token: self.minus_token(),
            literal_token: self.literal_token(),
        }
    }
    pub fn minus_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn literal_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for TsNumberLiteralType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNumberLiteralTypeFields {
    pub minus_token: Option<SyntaxToken>,
    pub literal_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsNumberType {
    pub(crate) syntax: SyntaxNode,
}
impl TsNumberType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsNumberTypeFields {
        TsNumberTypeFields {
            number_token: self.number_token(),
        }
    }
    pub fn number_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsNumberType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsNumberTypeFields {
    pub number_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsObjectType {
    pub(crate) syntax: SyntaxNode,
}
impl TsObjectType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsObjectTypeFields {
        TsObjectTypeFields {
            l_curly_token: self.l_curly_token(),
            members: self.members(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn l_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn members(&self) -> TsTypeMemberList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsObjectType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsObjectTypeFields {
    pub l_curly_token: SyntaxResult<SyntaxToken>,
    pub members: TsTypeMemberList,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsOptionalPropertyAnnotation {
    pub(crate) syntax: SyntaxNode,
}
impl TsOptionalPropertyAnnotation {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsOptionalPropertyAnnotationFields {
        TsOptionalPropertyAnnotationFields {
            question_mark_token: self.question_mark_token(),
            type_annotation: self.type_annotation(),
        }
    }
    pub fn question_mark_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for TsOptionalPropertyAnnotation {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsOptionalPropertyAnnotationFields {
    pub question_mark_token: SyntaxResult<SyntaxToken>,
    pub type_annotation: Option<TsTypeAnnotation>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsOptionalTupleTypeElement {
    pub(crate) syntax: SyntaxNode,
}
impl TsOptionalTupleTypeElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsOptionalTupleTypeElementFields {
        TsOptionalTupleTypeElementFields {
            ty: self.ty(),
            question_mark_token: self.question_mark_token(),
        }
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn question_mark_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
}
impl Serialize for TsOptionalTupleTypeElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsOptionalTupleTypeElementFields {
    pub ty: SyntaxResult<AnyTsType>,
    pub question_mark_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsOutModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsOutModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsOutModifierFields {
        TsOutModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsOutModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsOutModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsOverrideModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsOverrideModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsOverrideModifierFields {
        TsOverrideModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsOverrideModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsOverrideModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsParenthesizedType {
    pub(crate) syntax: SyntaxNode,
}
impl TsParenthesizedType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsParenthesizedTypeFields {
        TsParenthesizedTypeFields {
            l_paren_token: self.l_paren_token(),
            ty: self.ty(),
            r_paren_token: self.r_paren_token(),
        }
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsParenthesizedType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsParenthesizedTypeFields {
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsPredicateReturnType {
    pub(crate) syntax: SyntaxNode,
}
impl TsPredicateReturnType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsPredicateReturnTypeFields {
        TsPredicateReturnTypeFields {
            parameter_name: self.parameter_name(),
            is_token: self.is_token(),
            ty: self.ty(),
        }
    }
    pub fn parameter_name(&self) -> SyntaxResult<AnyTsTypePredicateParameterName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn is_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsPredicateReturnType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsPredicateReturnTypeFields {
    pub parameter_name: SyntaxResult<AnyTsTypePredicateParameterName>,
    pub is_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsPropertyParameter {
    pub(crate) syntax: SyntaxNode,
}
impl TsPropertyParameter {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsPropertyParameterFields {
        TsPropertyParameterFields {
            decorators: self.decorators(),
            modifiers: self.modifiers(),
            formal_parameter: self.formal_parameter(),
        }
    }
    pub fn decorators(&self) -> JsDecoratorList {
        support::list(&self.syntax, 0usize)
    }
    pub fn modifiers(&self) -> TsPropertyParameterModifierList {
        support::list(&self.syntax, 1usize)
    }
    pub fn formal_parameter(&self) -> SyntaxResult<AnyJsFormalParameter> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsPropertyParameter {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsPropertyParameterFields {
    pub decorators: JsDecoratorList,
    pub modifiers: TsPropertyParameterModifierList,
    pub formal_parameter: SyntaxResult<AnyJsFormalParameter>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsPropertySignatureClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsPropertySignatureClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsPropertySignatureClassMemberFields {
        TsPropertySignatureClassMemberFields {
            modifiers: self.modifiers(),
            name: self.name(),
            property_annotation: self.property_annotation(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> TsPropertySignatureModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn property_annotation(&self) -> Option<AnyTsPropertySignatureAnnotation> {
        support::node(&self.syntax, 2usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 3usize)
    }
}
impl Serialize for TsPropertySignatureClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsPropertySignatureClassMemberFields {
    pub modifiers: TsPropertySignatureModifierList,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub property_annotation: Option<AnyTsPropertySignatureAnnotation>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsPropertySignatureTypeMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsPropertySignatureTypeMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsPropertySignatureTypeMemberFields {
        TsPropertySignatureTypeMemberFields {
            readonly_token: self.readonly_token(),
            name: self.name(),
            optional_token: self.optional_token(),
            type_annotation: self.type_annotation(),
            separator_token: self.separator_token(),
        }
    }
    pub fn readonly_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn optional_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 2usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 3usize)
    }
    pub fn separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
}
impl Serialize for TsPropertySignatureTypeMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsPropertySignatureTypeMemberFields {
    pub readonly_token: Option<SyntaxToken>,
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub optional_token: Option<SyntaxToken>,
    pub type_annotation: Option<TsTypeAnnotation>,
    pub separator_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsQualifiedModuleName {
    pub(crate) syntax: SyntaxNode,
}
impl TsQualifiedModuleName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsQualifiedModuleNameFields {
        TsQualifiedModuleNameFields {
            left: self.left(),
            dot_token: self.dot_token(),
            right: self.right(),
        }
    }
    pub fn left(&self) -> SyntaxResult<AnyTsModuleName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn dot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn right(&self) -> SyntaxResult<JsName> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsQualifiedModuleName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsQualifiedModuleNameFields {
    pub left: SyntaxResult<AnyTsModuleName>,
    pub dot_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<JsName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsQualifiedName {
    pub(crate) syntax: SyntaxNode,
}
impl TsQualifiedName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsQualifiedNameFields {
        TsQualifiedNameFields {
            left: self.left(),
            dot_token: self.dot_token(),
            right: self.right(),
        }
    }
    pub fn left(&self) -> SyntaxResult<AnyTsName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn dot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn right(&self) -> SyntaxResult<JsName> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsQualifiedName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsQualifiedNameFields {
    pub left: SyntaxResult<AnyTsName>,
    pub dot_token: SyntaxResult<SyntaxToken>,
    pub right: SyntaxResult<JsName>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsReadonlyModifier {
    pub(crate) syntax: SyntaxNode,
}
impl TsReadonlyModifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsReadonlyModifierFields {
        TsReadonlyModifierFields {
            modifier_token: self.modifier_token(),
        }
    }
    pub fn modifier_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsReadonlyModifier {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsReadonlyModifierFields {
    pub modifier_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsReferenceType {
    pub(crate) syntax: SyntaxNode,
}
impl TsReferenceType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsReferenceTypeFields {
        TsReferenceTypeFields {
            name: self.name(),
            type_arguments: self.type_arguments(),
        }
    }
    pub fn name(&self) -> SyntaxResult<AnyTsName> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for TsReferenceType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsReferenceTypeFields {
    pub name: SyntaxResult<AnyTsName>,
    pub type_arguments: Option<TsTypeArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsRestTupleTypeElement {
    pub(crate) syntax: SyntaxNode,
}
impl TsRestTupleTypeElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsRestTupleTypeElementFields {
        TsRestTupleTypeElementFields {
            dotdotdot_token: self.dotdotdot_token(),
            ty: self.ty(),
        }
    }
    pub fn dotdotdot_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsRestTupleTypeElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsRestTupleTypeElementFields {
    pub dotdotdot_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsReturnTypeAnnotation {
    pub(crate) syntax: SyntaxNode,
}
impl TsReturnTypeAnnotation {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsReturnTypeAnnotationFields {
        TsReturnTypeAnnotationFields {
            colon_token: self.colon_token(),
            ty: self.ty(),
        }
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsReturnType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsReturnTypeAnnotation {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsReturnTypeAnnotationFields {
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsReturnType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsSatisfiesAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl TsSatisfiesAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsSatisfiesAssignmentFields {
        TsSatisfiesAssignmentFields {
            assignment: self.assignment(),
            satisfies_token: self.satisfies_token(),
            ty: self.ty(),
        }
    }
    pub fn assignment(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn satisfies_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsSatisfiesAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsSatisfiesAssignmentFields {
    pub assignment: SyntaxResult<AnyJsAssignment>,
    pub satisfies_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsSatisfiesExpression {
    pub(crate) syntax: SyntaxNode,
}
impl TsSatisfiesExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsSatisfiesExpressionFields {
        TsSatisfiesExpressionFields {
            expression: self.expression(),
            satisfies_token: self.satisfies_token(),
            ty: self.ty(),
        }
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 0usize)
    }
    pub fn satisfies_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 2usize)
    }
}
impl Serialize for TsSatisfiesExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsSatisfiesExpressionFields {
    pub expression: SyntaxResult<AnyJsExpression>,
    pub satisfies_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsSetterSignatureClassMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsSetterSignatureClassMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsSetterSignatureClassMemberFields {
        TsSetterSignatureClassMemberFields {
            modifiers: self.modifiers(),
            set_token: self.set_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            parameter: self.parameter(),
            comma_token: self.comma_token(),
            r_paren_token: self.r_paren_token(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn modifiers(&self) -> TsMethodSignatureModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn set_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 1usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsClassMemberName> {
        support::required_node(&self.syntax, 2usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn parameter(&self) -> SyntaxResult<AnyJsFormalParameter> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn comma_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 6usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 7usize)
    }
}
impl Serialize for TsSetterSignatureClassMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsSetterSignatureClassMemberFields {
    pub modifiers: TsMethodSignatureModifierList,
    pub set_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsClassMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub parameter: SyntaxResult<AnyJsFormalParameter>,
    pub comma_token: Option<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsSetterSignatureTypeMember {
    pub(crate) syntax: SyntaxNode,
}
impl TsSetterSignatureTypeMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsSetterSignatureTypeMemberFields {
        TsSetterSignatureTypeMemberFields {
            set_token: self.set_token(),
            name: self.name(),
            l_paren_token: self.l_paren_token(),
            parameter: self.parameter(),
            comma_token: self.comma_token(),
            r_paren_token: self.r_paren_token(),
            separator_token: self.separator_token(),
        }
    }
    pub fn set_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<AnyJsObjectMemberName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn l_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn parameter(&self) -> SyntaxResult<AnyJsFormalParameter> {
        support::required_node(&self.syntax, 3usize)
    }
    pub fn comma_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 4usize)
    }
    pub fn r_paren_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 5usize)
    }
    pub fn separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 6usize)
    }
}
impl Serialize for TsSetterSignatureTypeMember {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsSetterSignatureTypeMemberFields {
    pub set_token: SyntaxResult<SyntaxToken>,
    pub name: SyntaxResult<AnyJsObjectMemberName>,
    pub l_paren_token: SyntaxResult<SyntaxToken>,
    pub parameter: SyntaxResult<AnyJsFormalParameter>,
    pub comma_token: Option<SyntaxToken>,
    pub r_paren_token: SyntaxResult<SyntaxToken>,
    pub separator_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsStringLiteralType {
    pub(crate) syntax: SyntaxNode,
}
impl TsStringLiteralType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsStringLiteralTypeFields {
        TsStringLiteralTypeFields {
            literal_token: self.literal_token(),
        }
    }
    pub fn literal_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsStringLiteralType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsStringLiteralTypeFields {
    pub literal_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsStringType {
    pub(crate) syntax: SyntaxNode,
}
impl TsStringType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsStringTypeFields {
        TsStringTypeFields {
            string_token: self.string_token(),
        }
    }
    pub fn string_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsStringType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsStringTypeFields {
    pub string_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsSymbolType {
    pub(crate) syntax: SyntaxNode,
}
impl TsSymbolType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsSymbolTypeFields {
        TsSymbolTypeFields {
            symbol_token: self.symbol_token(),
        }
    }
    pub fn symbol_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsSymbolType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsSymbolTypeFields {
    pub symbol_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTemplateChunkElement {
    pub(crate) syntax: SyntaxNode,
}
impl TsTemplateChunkElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTemplateChunkElementFields {
        TsTemplateChunkElementFields {
            template_chunk_token: self.template_chunk_token(),
        }
    }
    pub fn template_chunk_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsTemplateChunkElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTemplateChunkElementFields {
    pub template_chunk_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTemplateElement {
    pub(crate) syntax: SyntaxNode,
}
impl TsTemplateElement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTemplateElementFields {
        TsTemplateElementFields {
            dollar_curly_token: self.dollar_curly_token(),
            ty: self.ty(),
            r_curly_token: self.r_curly_token(),
        }
    }
    pub fn dollar_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_curly_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsTemplateElement {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTemplateElementFields {
    pub dollar_curly_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
    pub r_curly_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTemplateLiteralType {
    pub(crate) syntax: SyntaxNode,
}
impl TsTemplateLiteralType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTemplateLiteralTypeFields {
        TsTemplateLiteralTypeFields {
            l_tick_token: self.l_tick_token(),
            elements: self.elements(),
            r_tick_token: self.r_tick_token(),
        }
    }
    pub fn l_tick_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn elements(&self) -> TsTemplateElementList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_tick_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsTemplateLiteralType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTemplateLiteralTypeFields {
    pub l_tick_token: SyntaxResult<SyntaxToken>,
    pub elements: TsTemplateElementList,
    pub r_tick_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsThisParameter {
    pub(crate) syntax: SyntaxNode,
}
impl TsThisParameter {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsThisParameterFields {
        TsThisParameterFields {
            this_token: self.this_token(),
            type_annotation: self.type_annotation(),
        }
    }
    pub fn this_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn type_annotation(&self) -> Option<TsTypeAnnotation> {
        support::node(&self.syntax, 1usize)
    }
}
impl Serialize for TsThisParameter {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsThisParameterFields {
    pub this_token: SyntaxResult<SyntaxToken>,
    pub type_annotation: Option<TsTypeAnnotation>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsThisType {
    pub(crate) syntax: SyntaxNode,
}
impl TsThisType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsThisTypeFields {
        TsThisTypeFields {
            this_token: self.this_token(),
        }
    }
    pub fn this_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsThisType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsThisTypeFields {
    pub this_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTupleType {
    pub(crate) syntax: SyntaxNode,
}
impl TsTupleType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTupleTypeFields {
        TsTupleTypeFields {
            l_brack_token: self.l_brack_token(),
            elements: self.elements(),
            r_brack_token: self.r_brack_token(),
        }
    }
    pub fn l_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn elements(&self) -> TsTupleTypeElementList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_brack_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsTupleType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTupleTypeFields {
    pub l_brack_token: SyntaxResult<SyntaxToken>,
    pub elements: TsTupleTypeElementList,
    pub r_brack_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeAliasDeclaration {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeAliasDeclaration {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeAliasDeclarationFields {
        TsTypeAliasDeclarationFields {
            type_token: self.type_token(),
            binding_identifier: self.binding_identifier(),
            type_parameters: self.type_parameters(),
            eq_token: self.eq_token(),
            ty: self.ty(),
            semicolon_token: self.semicolon_token(),
        }
    }
    pub fn type_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn binding_identifier(&self) -> SyntaxResult<AnyTsIdentifierBinding> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_parameters(&self) -> Option<TsTypeParameters> {
        support::node(&self.syntax, 2usize)
    }
    pub fn eq_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 3usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 4usize)
    }
    pub fn semicolon_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 5usize)
    }
}
impl Serialize for TsTypeAliasDeclaration {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeAliasDeclarationFields {
    pub type_token: SyntaxResult<SyntaxToken>,
    pub binding_identifier: SyntaxResult<AnyTsIdentifierBinding>,
    pub type_parameters: Option<TsTypeParameters>,
    pub eq_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
    pub semicolon_token: Option<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeAnnotation {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeAnnotation {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeAnnotationFields {
        TsTypeAnnotationFields {
            colon_token: self.colon_token(),
            ty: self.ty(),
        }
    }
    pub fn colon_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsTypeAnnotation {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeAnnotationFields {
    pub colon_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeArguments {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeArguments {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeArgumentsFields {
        TsTypeArgumentsFields {
            l_angle_token: self.l_angle_token(),
            ts_type_argument_list: self.ts_type_argument_list(),
            r_angle_token: self.r_angle_token(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ts_type_argument_list(&self) -> TsTypeArgumentList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsTypeArguments {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeArgumentsFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub ts_type_argument_list: TsTypeArgumentList,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeAssertionAssignment {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeAssertionAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeAssertionAssignmentFields {
        TsTypeAssertionAssignmentFields {
            l_angle_token: self.l_angle_token(),
            ty: self.ty(),
            r_angle_token: self.r_angle_token(),
            assignment: self.assignment(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn assignment(&self) -> SyntaxResult<AnyJsAssignment> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for TsTypeAssertionAssignment {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeAssertionAssignmentFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
    pub assignment: SyntaxResult<AnyJsAssignment>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeAssertionExpression {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeAssertionExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeAssertionExpressionFields {
        TsTypeAssertionExpressionFields {
            l_angle_token: self.l_angle_token(),
            ty: self.ty(),
            r_angle_token: self.r_angle_token(),
            expression: self.expression(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
    pub fn expression(&self) -> SyntaxResult<AnyJsExpression> {
        support::required_node(&self.syntax, 3usize)
    }
}
impl Serialize for TsTypeAssertionExpression {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeAssertionExpressionFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
    pub expression: SyntaxResult<AnyJsExpression>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeConstraintClause {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeConstraintClause {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeConstraintClauseFields {
        TsTypeConstraintClauseFields {
            extends_token: self.extends_token(),
            ty: self.ty(),
        }
    }
    pub fn extends_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsTypeConstraintClause {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeConstraintClauseFields {
    pub extends_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeOperatorType {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeOperatorType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeOperatorTypeFields {
        TsTypeOperatorTypeFields {
            operator_token: self.operator_token(),
            ty: self.ty(),
        }
    }
    pub fn operator_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn ty(&self) -> SyntaxResult<AnyTsType> {
        support::required_node(&self.syntax, 1usize)
    }
}
impl Serialize for TsTypeOperatorType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeOperatorTypeFields {
    pub operator_token: SyntaxResult<SyntaxToken>,
    pub ty: SyntaxResult<AnyTsType>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeParameter {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeParameter {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeParameterFields {
        TsTypeParameterFields {
            modifiers: self.modifiers(),
            name: self.name(),
            constraint: self.constraint(),
            default: self.default(),
        }
    }
    pub fn modifiers(&self) -> TsTypeParameterModifierList {
        support::list(&self.syntax, 0usize)
    }
    pub fn name(&self) -> SyntaxResult<TsTypeParameterName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn constraint(&self) -> Option<TsTypeConstraintClause> {
        support::node(&self.syntax, 2usize)
    }
    pub fn default(&self) -> Option<TsDefaultTypeClause> {
        support::node(&self.syntax, 3usize)
    }
}
impl Serialize for TsTypeParameter {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeParameterFields {
    pub modifiers: TsTypeParameterModifierList,
    pub name: SyntaxResult<TsTypeParameterName>,
    pub constraint: Option<TsTypeConstraintClause>,
    pub default: Option<TsDefaultTypeClause>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeParameterName {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeParameterName {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeParameterNameFields {
        TsTypeParameterNameFields {
            ident_token: self.ident_token(),
        }
    }
    pub fn ident_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsTypeParameterName {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeParameterNameFields {
    pub ident_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeParameters {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeParameters {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeParametersFields {
        TsTypeParametersFields {
            l_angle_token: self.l_angle_token(),
            items: self.items(),
            r_angle_token: self.r_angle_token(),
        }
    }
    pub fn l_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn items(&self) -> TsTypeParameterList {
        support::list(&self.syntax, 1usize)
    }
    pub fn r_angle_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 2usize)
    }
}
impl Serialize for TsTypeParameters {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeParametersFields {
    pub l_angle_token: SyntaxResult<SyntaxToken>,
    pub items: TsTypeParameterList,
    pub r_angle_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsTypeofType {
    pub(crate) syntax: SyntaxNode,
}
impl TsTypeofType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsTypeofTypeFields {
        TsTypeofTypeFields {
            typeof_token: self.typeof_token(),
            expression_name: self.expression_name(),
            type_arguments: self.type_arguments(),
        }
    }
    pub fn typeof_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
    pub fn expression_name(&self) -> SyntaxResult<AnyTsName> {
        support::required_node(&self.syntax, 1usize)
    }
    pub fn type_arguments(&self) -> Option<TsTypeArguments> {
        support::node(&self.syntax, 2usize)
    }
}
impl Serialize for TsTypeofType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsTypeofTypeFields {
    pub typeof_token: SyntaxResult<SyntaxToken>,
    pub expression_name: SyntaxResult<AnyTsName>,
    pub type_arguments: Option<TsTypeArguments>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsUndefinedType {
    pub(crate) syntax: SyntaxNode,
}
impl TsUndefinedType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsUndefinedTypeFields {
        TsUndefinedTypeFields {
            undefined_token: self.undefined_token(),
        }
    }
    pub fn undefined_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsUndefinedType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsUndefinedTypeFields {
    pub undefined_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsUnionType {
    pub(crate) syntax: SyntaxNode,
}
impl TsUnionType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsUnionTypeFields {
        TsUnionTypeFields {
            leading_separator_token: self.leading_separator_token(),
            types: self.types(),
        }
    }
    pub fn leading_separator_token(&self) -> Option<SyntaxToken> {
        support::token(&self.syntax, 0usize)
    }
    pub fn types(&self) -> TsUnionTypeVariantList {
        support::list(&self.syntax, 1usize)
    }
}
impl Serialize for TsUnionType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsUnionTypeFields {
    pub leading_separator_token: Option<SyntaxToken>,
    pub types: TsUnionTypeVariantList,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsUnknownType {
    pub(crate) syntax: SyntaxNode,
}
impl TsUnknownType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsUnknownTypeFields {
        TsUnknownTypeFields {
            unknown_token: self.unknown_token(),
        }
    }
    pub fn unknown_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsUnknownType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsUnknownTypeFields {
    pub unknown_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct TsVoidType {
    pub(crate) syntax: SyntaxNode,
}
impl TsVoidType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn as_fields(&self) -> TsVoidTypeFields {
        TsVoidTypeFields {
            void_token: self.void_token(),
        }
    }
    pub fn void_token(&self) -> SyntaxResult<SyntaxToken> {
        support::required_token(&self.syntax, 0usize)
    }
}
impl Serialize for TsVoidType {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        self.as_fields().serialize(serializer)
    }
}
#[derive(Serialize)]
pub struct TsVoidTypeFields {
    pub void_token: SyntaxResult<SyntaxToken>,
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsArrayAssignmentPatternElement {
    JsArrayAssignmentPatternElement(JsArrayAssignmentPatternElement),
    JsArrayAssignmentPatternRestElement(JsArrayAssignmentPatternRestElement),
    JsArrayHole(JsArrayHole),
}
impl AnyJsArrayAssignmentPatternElement {
    pub fn as_js_array_assignment_pattern_element(
        &self,
    ) -> Option<&JsArrayAssignmentPatternElement> {
        match &self {
            Self::JsArrayAssignmentPatternElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_assignment_pattern_rest_element(
        &self,
    ) -> Option<&JsArrayAssignmentPatternRestElement> {
        match &self {
            Self::JsArrayAssignmentPatternRestElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_hole(&self) -> Option<&JsArrayHole> {
        match &self {
            Self::JsArrayHole(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsArrayBindingPatternElement {
    JsArrayBindingPatternElement(JsArrayBindingPatternElement),
    JsArrayBindingPatternRestElement(JsArrayBindingPatternRestElement),
    JsArrayHole(JsArrayHole),
}
impl AnyJsArrayBindingPatternElement {
    pub fn as_js_array_binding_pattern_element(&self) -> Option<&JsArrayBindingPatternElement> {
        match &self {
            Self::JsArrayBindingPatternElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_binding_pattern_rest_element(
        &self,
    ) -> Option<&JsArrayBindingPatternRestElement> {
        match &self {
            Self::JsArrayBindingPatternRestElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_hole(&self) -> Option<&JsArrayHole> {
        match &self {
            Self::JsArrayHole(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsArrayElement {
    AnyJsExpression(AnyJsExpression),
    JsArrayHole(JsArrayHole),
    JsSpread(JsSpread),
}
impl AnyJsArrayElement {
    pub fn as_any_js_expression(&self) -> Option<&AnyJsExpression> {
        match &self {
            Self::AnyJsExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_hole(&self) -> Option<&JsArrayHole> {
        match &self {
            Self::JsArrayHole(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_spread(&self) -> Option<&JsSpread> {
        match &self {
            Self::JsSpread(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsArrowFunctionParameters {
    AnyJsBinding(AnyJsBinding),
    JsParameters(JsParameters),
}
impl AnyJsArrowFunctionParameters {
    pub fn as_any_js_binding(&self) -> Option<&AnyJsBinding> {
        match &self {
            Self::AnyJsBinding(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_parameters(&self) -> Option<&JsParameters> {
        match &self {
            Self::JsParameters(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsAssignment {
    JsBogusAssignment(JsBogusAssignment),
    JsComputedMemberAssignment(JsComputedMemberAssignment),
    JsIdentifierAssignment(JsIdentifierAssignment),
    JsParenthesizedAssignment(JsParenthesizedAssignment),
    JsStaticMemberAssignment(JsStaticMemberAssignment),
    TsAsAssignment(TsAsAssignment),
    TsNonNullAssertionAssignment(TsNonNullAssertionAssignment),
    TsSatisfiesAssignment(TsSatisfiesAssignment),
    TsTypeAssertionAssignment(TsTypeAssertionAssignment),
}
impl AnyJsAssignment {
    pub fn as_js_bogus_assignment(&self) -> Option<&JsBogusAssignment> {
        match &self {
            Self::JsBogusAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_computed_member_assignment(&self) -> Option<&JsComputedMemberAssignment> {
        match &self {
            Self::JsComputedMemberAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_identifier_assignment(&self) -> Option<&JsIdentifierAssignment> {
        match &self {
            Self::JsIdentifierAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_parenthesized_assignment(&self) -> Option<&JsParenthesizedAssignment> {
        match &self {
            Self::JsParenthesizedAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_member_assignment(&self) -> Option<&JsStaticMemberAssignment> {
        match &self {
            Self::JsStaticMemberAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_as_assignment(&self) -> Option<&TsAsAssignment> {
        match &self {
            Self::TsAsAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_non_null_assertion_assignment(&self) -> Option<&TsNonNullAssertionAssignment> {
        match &self {
            Self::TsNonNullAssertionAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_satisfies_assignment(&self) -> Option<&TsSatisfiesAssignment> {
        match &self {
            Self::TsSatisfiesAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_assertion_assignment(&self) -> Option<&TsTypeAssertionAssignment> {
        match &self {
            Self::TsTypeAssertionAssignment(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsAssignmentPattern {
    AnyJsAssignment(AnyJsAssignment),
    JsArrayAssignmentPattern(JsArrayAssignmentPattern),
    JsObjectAssignmentPattern(JsObjectAssignmentPattern),
}
impl AnyJsAssignmentPattern {
    pub fn as_any_js_assignment(&self) -> Option<&AnyJsAssignment> {
        match &self {
            Self::AnyJsAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_assignment_pattern(&self) -> Option<&JsArrayAssignmentPattern> {
        match &self {
            Self::JsArrayAssignmentPattern(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_assignment_pattern(&self) -> Option<&JsObjectAssignmentPattern> {
        match &self {
            Self::JsObjectAssignmentPattern(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsBinding {
    JsBogusBinding(JsBogusBinding),
    JsIdentifierBinding(JsIdentifierBinding),
    JsMetavariable(JsMetavariable),
}
impl AnyJsBinding {
    pub fn as_js_bogus_binding(&self) -> Option<&JsBogusBinding> {
        match &self {
            Self::JsBogusBinding(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_identifier_binding(&self) -> Option<&JsIdentifierBinding> {
        match &self {
            Self::JsIdentifierBinding(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsBindingPattern {
    AnyJsBinding(AnyJsBinding),
    JsArrayBindingPattern(JsArrayBindingPattern),
    JsObjectBindingPattern(JsObjectBindingPattern),
}
impl AnyJsBindingPattern {
    pub fn as_any_js_binding(&self) -> Option<&AnyJsBinding> {
        match &self {
            Self::AnyJsBinding(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_binding_pattern(&self) -> Option<&JsArrayBindingPattern> {
        match &self {
            Self::JsArrayBindingPattern(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_binding_pattern(&self) -> Option<&JsObjectBindingPattern> {
        match &self {
            Self::JsObjectBindingPattern(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsCallArgument {
    AnyJsExpression(AnyJsExpression),
    JsSpread(JsSpread),
}
impl AnyJsCallArgument {
    pub fn as_any_js_expression(&self) -> Option<&AnyJsExpression> {
        match &self {
            Self::AnyJsExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_spread(&self) -> Option<&JsSpread> {
        match &self {
            Self::JsSpread(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsClass {
    JsClassDeclaration(JsClassDeclaration),
    JsClassExportDefaultDeclaration(JsClassExportDefaultDeclaration),
    JsClassExpression(JsClassExpression),
}
impl AnyJsClass {
    pub fn as_js_class_declaration(&self) -> Option<&JsClassDeclaration> {
        match &self {
            Self::JsClassDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_class_export_default_declaration(
        &self,
    ) -> Option<&JsClassExportDefaultDeclaration> {
        match &self {
            Self::JsClassExportDefaultDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_class_expression(&self) -> Option<&JsClassExpression> {
        match &self {
            Self::JsClassExpression(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsClassMember {
    JsBogusMember(JsBogusMember),
    JsConstructorClassMember(JsConstructorClassMember),
    JsEmptyClassMember(JsEmptyClassMember),
    JsGetterClassMember(JsGetterClassMember),
    JsMetavariable(JsMetavariable),
    JsMethodClassMember(JsMethodClassMember),
    JsPropertyClassMember(JsPropertyClassMember),
    JsSetterClassMember(JsSetterClassMember),
    JsStaticInitializationBlockClassMember(JsStaticInitializationBlockClassMember),
    TsConstructorSignatureClassMember(TsConstructorSignatureClassMember),
    TsGetterSignatureClassMember(TsGetterSignatureClassMember),
    TsIndexSignatureClassMember(TsIndexSignatureClassMember),
    TsInitializedPropertySignatureClassMember(TsInitializedPropertySignatureClassMember),
    TsMethodSignatureClassMember(TsMethodSignatureClassMember),
    TsPropertySignatureClassMember(TsPropertySignatureClassMember),
    TsSetterSignatureClassMember(TsSetterSignatureClassMember),
}
impl AnyJsClassMember {
    pub fn as_js_bogus_member(&self) -> Option<&JsBogusMember> {
        match &self {
            Self::JsBogusMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_constructor_class_member(&self) -> Option<&JsConstructorClassMember> {
        match &self {
            Self::JsConstructorClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_empty_class_member(&self) -> Option<&JsEmptyClassMember> {
        match &self {
            Self::JsEmptyClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_getter_class_member(&self) -> Option<&JsGetterClassMember> {
        match &self {
            Self::JsGetterClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_method_class_member(&self) -> Option<&JsMethodClassMember> {
        match &self {
            Self::JsMethodClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_property_class_member(&self) -> Option<&JsPropertyClassMember> {
        match &self {
            Self::JsPropertyClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_setter_class_member(&self) -> Option<&JsSetterClassMember> {
        match &self {
            Self::JsSetterClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_initialization_block_class_member(
        &self,
    ) -> Option<&JsStaticInitializationBlockClassMember> {
        match &self {
            Self::JsStaticInitializationBlockClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_constructor_signature_class_member(
        &self,
    ) -> Option<&TsConstructorSignatureClassMember> {
        match &self {
            Self::TsConstructorSignatureClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_getter_signature_class_member(&self) -> Option<&TsGetterSignatureClassMember> {
        match &self {
            Self::TsGetterSignatureClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_index_signature_class_member(&self) -> Option<&TsIndexSignatureClassMember> {
        match &self {
            Self::TsIndexSignatureClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_initialized_property_signature_class_member(
        &self,
    ) -> Option<&TsInitializedPropertySignatureClassMember> {
        match &self {
            Self::TsInitializedPropertySignatureClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_method_signature_class_member(&self) -> Option<&TsMethodSignatureClassMember> {
        match &self {
            Self::TsMethodSignatureClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_property_signature_class_member(&self) -> Option<&TsPropertySignatureClassMember> {
        match &self {
            Self::TsPropertySignatureClassMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_setter_signature_class_member(&self) -> Option<&TsSetterSignatureClassMember> {
        match &self {
            Self::TsSetterSignatureClassMember(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsClassMemberName {
    JsComputedMemberName(JsComputedMemberName),
    JsLiteralMemberName(JsLiteralMemberName),
    JsMetavariable(JsMetavariable),
    JsPrivateClassMemberName(JsPrivateClassMemberName),
}
impl AnyJsClassMemberName {
    pub fn as_js_computed_member_name(&self) -> Option<&JsComputedMemberName> {
        match &self {
            Self::JsComputedMemberName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_literal_member_name(&self) -> Option<&JsLiteralMemberName> {
        match &self {
            Self::JsLiteralMemberName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_private_class_member_name(&self) -> Option<&JsPrivateClassMemberName> {
        match &self {
            Self::JsPrivateClassMemberName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsCombinedSpecifier {
    JsNamedImportSpecifiers(JsNamedImportSpecifiers),
    JsNamespaceImportSpecifier(JsNamespaceImportSpecifier),
}
impl AnyJsCombinedSpecifier {
    pub fn as_js_named_import_specifiers(&self) -> Option<&JsNamedImportSpecifiers> {
        match &self {
            Self::JsNamedImportSpecifiers(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_namespace_import_specifier(&self) -> Option<&JsNamespaceImportSpecifier> {
        match &self {
            Self::JsNamespaceImportSpecifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsConstructorParameter {
    AnyJsFormalParameter(AnyJsFormalParameter),
    JsRestParameter(JsRestParameter),
    TsPropertyParameter(TsPropertyParameter),
}
impl AnyJsConstructorParameter {
    pub fn as_any_js_formal_parameter(&self) -> Option<&AnyJsFormalParameter> {
        match &self {
            Self::AnyJsFormalParameter(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_rest_parameter(&self) -> Option<&JsRestParameter> {
        match &self {
            Self::JsRestParameter(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_property_parameter(&self) -> Option<&TsPropertyParameter> {
        match &self {
            Self::TsPropertyParameter(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsDeclaration {
    JsClassDeclaration(JsClassDeclaration),
    JsFunctionDeclaration(JsFunctionDeclaration),
    JsVariableDeclaration(JsVariableDeclaration),
    TsDeclareFunctionDeclaration(TsDeclareFunctionDeclaration),
    TsEnumDeclaration(TsEnumDeclaration),
    TsExternalModuleDeclaration(TsExternalModuleDeclaration),
    TsGlobalDeclaration(TsGlobalDeclaration),
    TsImportEqualsDeclaration(TsImportEqualsDeclaration),
    TsInterfaceDeclaration(TsInterfaceDeclaration),
    TsModuleDeclaration(TsModuleDeclaration),
    TsTypeAliasDeclaration(TsTypeAliasDeclaration),
}
impl AnyJsDeclaration {
    pub fn as_js_class_declaration(&self) -> Option<&JsClassDeclaration> {
        match &self {
            Self::JsClassDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_declaration(&self) -> Option<&JsFunctionDeclaration> {
        match &self {
            Self::JsFunctionDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_variable_declaration(&self) -> Option<&JsVariableDeclaration> {
        match &self {
            Self::JsVariableDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_declare_function_declaration(&self) -> Option<&TsDeclareFunctionDeclaration> {
        match &self {
            Self::TsDeclareFunctionDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_enum_declaration(&self) -> Option<&TsEnumDeclaration> {
        match &self {
            Self::TsEnumDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_external_module_declaration(&self) -> Option<&TsExternalModuleDeclaration> {
        match &self {
            Self::TsExternalModuleDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_global_declaration(&self) -> Option<&TsGlobalDeclaration> {
        match &self {
            Self::TsGlobalDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_import_equals_declaration(&self) -> Option<&TsImportEqualsDeclaration> {
        match &self {
            Self::TsImportEqualsDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_interface_declaration(&self) -> Option<&TsInterfaceDeclaration> {
        match &self {
            Self::TsInterfaceDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_module_declaration(&self) -> Option<&TsModuleDeclaration> {
        match &self {
            Self::TsModuleDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_alias_declaration(&self) -> Option<&TsTypeAliasDeclaration> {
        match &self {
            Self::TsTypeAliasDeclaration(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsDeclarationClause {
    JsClassDeclaration(JsClassDeclaration),
    JsFunctionDeclaration(JsFunctionDeclaration),
    JsVariableDeclarationClause(JsVariableDeclarationClause),
    TsDeclareFunctionDeclaration(TsDeclareFunctionDeclaration),
    TsEnumDeclaration(TsEnumDeclaration),
    TsExternalModuleDeclaration(TsExternalModuleDeclaration),
    TsGlobalDeclaration(TsGlobalDeclaration),
    TsImportEqualsDeclaration(TsImportEqualsDeclaration),
    TsInterfaceDeclaration(TsInterfaceDeclaration),
    TsModuleDeclaration(TsModuleDeclaration),
    TsTypeAliasDeclaration(TsTypeAliasDeclaration),
}
impl AnyJsDeclarationClause {
    pub fn as_js_class_declaration(&self) -> Option<&JsClassDeclaration> {
        match &self {
            Self::JsClassDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_declaration(&self) -> Option<&JsFunctionDeclaration> {
        match &self {
            Self::JsFunctionDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_variable_declaration_clause(&self) -> Option<&JsVariableDeclarationClause> {
        match &self {
            Self::JsVariableDeclarationClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_declare_function_declaration(&self) -> Option<&TsDeclareFunctionDeclaration> {
        match &self {
            Self::TsDeclareFunctionDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_enum_declaration(&self) -> Option<&TsEnumDeclaration> {
        match &self {
            Self::TsEnumDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_external_module_declaration(&self) -> Option<&TsExternalModuleDeclaration> {
        match &self {
            Self::TsExternalModuleDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_global_declaration(&self) -> Option<&TsGlobalDeclaration> {
        match &self {
            Self::TsGlobalDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_import_equals_declaration(&self) -> Option<&TsImportEqualsDeclaration> {
        match &self {
            Self::TsImportEqualsDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_interface_declaration(&self) -> Option<&TsInterfaceDeclaration> {
        match &self {
            Self::TsInterfaceDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_module_declaration(&self) -> Option<&TsModuleDeclaration> {
        match &self {
            Self::TsModuleDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_alias_declaration(&self) -> Option<&TsTypeAliasDeclaration> {
        match &self {
            Self::TsTypeAliasDeclaration(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsDecorator {
    JsBogusExpression(JsBogusExpression),
    JsCallExpression(JsCallExpression),
    JsIdentifierExpression(JsIdentifierExpression),
    JsParenthesizedExpression(JsParenthesizedExpression),
    JsStaticMemberExpression(JsStaticMemberExpression),
}
impl AnyJsDecorator {
    pub fn as_js_bogus_expression(&self) -> Option<&JsBogusExpression> {
        match &self {
            Self::JsBogusExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_call_expression(&self) -> Option<&JsCallExpression> {
        match &self {
            Self::JsCallExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_identifier_expression(&self) -> Option<&JsIdentifierExpression> {
        match &self {
            Self::JsIdentifierExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_parenthesized_expression(&self) -> Option<&JsParenthesizedExpression> {
        match &self {
            Self::JsParenthesizedExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_member_expression(&self) -> Option<&JsStaticMemberExpression> {
        match &self {
            Self::JsStaticMemberExpression(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsExportClause {
    AnyJsDeclarationClause(AnyJsDeclarationClause),
    JsExportDefaultDeclarationClause(JsExportDefaultDeclarationClause),
    JsExportDefaultExpressionClause(JsExportDefaultExpressionClause),
    JsExportFromClause(JsExportFromClause),
    JsExportNamedClause(JsExportNamedClause),
    JsExportNamedFromClause(JsExportNamedFromClause),
    TsExportAsNamespaceClause(TsExportAsNamespaceClause),
    TsExportAssignmentClause(TsExportAssignmentClause),
    TsExportDeclareClause(TsExportDeclareClause),
}
impl AnyJsExportClause {
    pub fn as_any_js_declaration_clause(&self) -> Option<&AnyJsDeclarationClause> {
        match &self {
            Self::AnyJsDeclarationClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_export_default_declaration_clause(
        &self,
    ) -> Option<&JsExportDefaultDeclarationClause> {
        match &self {
            Self::JsExportDefaultDeclarationClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_export_default_expression_clause(
        &self,
    ) -> Option<&JsExportDefaultExpressionClause> {
        match &self {
            Self::JsExportDefaultExpressionClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_export_from_clause(&self) -> Option<&JsExportFromClause> {
        match &self {
            Self::JsExportFromClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_export_named_clause(&self) -> Option<&JsExportNamedClause> {
        match &self {
            Self::JsExportNamedClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_export_named_from_clause(&self) -> Option<&JsExportNamedFromClause> {
        match &self {
            Self::JsExportNamedFromClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_export_as_namespace_clause(&self) -> Option<&TsExportAsNamespaceClause> {
        match &self {
            Self::TsExportAsNamespaceClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_export_assignment_clause(&self) -> Option<&TsExportAssignmentClause> {
        match &self {
            Self::TsExportAssignmentClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_export_declare_clause(&self) -> Option<&TsExportDeclareClause> {
        match &self {
            Self::TsExportDeclareClause(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsExportDefaultDeclaration {
    JsClassExportDefaultDeclaration(JsClassExportDefaultDeclaration),
    JsFunctionExportDefaultDeclaration(JsFunctionExportDefaultDeclaration),
    TsDeclareFunctionExportDefaultDeclaration(TsDeclareFunctionExportDefaultDeclaration),
    TsInterfaceDeclaration(TsInterfaceDeclaration),
}
impl AnyJsExportDefaultDeclaration {
    pub fn as_js_class_export_default_declaration(
        &self,
    ) -> Option<&JsClassExportDefaultDeclaration> {
        match &self {
            Self::JsClassExportDefaultDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_export_default_declaration(
        &self,
    ) -> Option<&JsFunctionExportDefaultDeclaration> {
        match &self {
            Self::JsFunctionExportDefaultDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_declare_function_export_default_declaration(
        &self,
    ) -> Option<&TsDeclareFunctionExportDefaultDeclaration> {
        match &self {
            Self::TsDeclareFunctionExportDefaultDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_interface_declaration(&self) -> Option<&TsInterfaceDeclaration> {
        match &self {
            Self::TsInterfaceDeclaration(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsExportNamedSpecifier {
    JsExportNamedShorthandSpecifier(JsExportNamedShorthandSpecifier),
    JsExportNamedSpecifier(JsExportNamedSpecifier),
}
impl AnyJsExportNamedSpecifier {
    pub fn as_js_export_named_shorthand_specifier(
        &self,
    ) -> Option<&JsExportNamedShorthandSpecifier> {
        match &self {
            Self::JsExportNamedShorthandSpecifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_export_named_specifier(&self) -> Option<&JsExportNamedSpecifier> {
        match &self {
            Self::JsExportNamedSpecifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsExpression {
    AnyJsLiteralExpression(AnyJsLiteralExpression),
    JsArrayExpression(JsArrayExpression),
    JsArrowFunctionExpression(JsArrowFunctionExpression),
    JsAssignmentExpression(JsAssignmentExpression),
    JsAwaitExpression(JsAwaitExpression),
    JsBinaryExpression(JsBinaryExpression),
    JsBogusExpression(JsBogusExpression),
    JsCallExpression(JsCallExpression),
    JsClassExpression(JsClassExpression),
    JsComputedMemberExpression(JsComputedMemberExpression),
    JsConditionalExpression(JsConditionalExpression),
    JsFunctionExpression(JsFunctionExpression),
    JsIdentifierExpression(JsIdentifierExpression),
    JsImportCallExpression(JsImportCallExpression),
    JsImportMetaExpression(JsImportMetaExpression),
    JsInExpression(JsInExpression),
    JsInstanceofExpression(JsInstanceofExpression),
    JsLogicalExpression(JsLogicalExpression),
    JsMetavariable(JsMetavariable),
    JsNewExpression(JsNewExpression),
    JsNewTargetExpression(JsNewTargetExpression),
    JsObjectExpression(JsObjectExpression),
    JsParenthesizedExpression(JsParenthesizedExpression),
    JsPostUpdateExpression(JsPostUpdateExpression),
    JsPreUpdateExpression(JsPreUpdateExpression),
    JsSequenceExpression(JsSequenceExpression),
    JsStaticMemberExpression(JsStaticMemberExpression),
    JsSuperExpression(JsSuperExpression),
    JsTemplateExpression(JsTemplateExpression),
    JsThisExpression(JsThisExpression),
    JsUnaryExpression(JsUnaryExpression),
    JsYieldExpression(JsYieldExpression),
    JsxTagExpression(JsxTagExpression),
    TsAsExpression(TsAsExpression),
    TsInstantiationExpression(TsInstantiationExpression),
    TsNonNullAssertionExpression(TsNonNullAssertionExpression),
    TsSatisfiesExpression(TsSatisfiesExpression),
    TsTypeAssertionExpression(TsTypeAssertionExpression),
}
impl AnyJsExpression {
    pub fn as_any_js_literal_expression(&self) -> Option<&AnyJsLiteralExpression> {
        match &self {
            Self::AnyJsLiteralExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_array_expression(&self) -> Option<&JsArrayExpression> {
        match &self {
            Self::JsArrayExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_arrow_function_expression(&self) -> Option<&JsArrowFunctionExpression> {
        match &self {
            Self::JsArrowFunctionExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_assignment_expression(&self) -> Option<&JsAssignmentExpression> {
        match &self {
            Self::JsAssignmentExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_await_expression(&self) -> Option<&JsAwaitExpression> {
        match &self {
            Self::JsAwaitExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_binary_expression(&self) -> Option<&JsBinaryExpression> {
        match &self {
            Self::JsBinaryExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_bogus_expression(&self) -> Option<&JsBogusExpression> {
        match &self {
            Self::JsBogusExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_call_expression(&self) -> Option<&JsCallExpression> {
        match &self {
            Self::JsCallExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_class_expression(&self) -> Option<&JsClassExpression> {
        match &self {
            Self::JsClassExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_computed_member_expression(&self) -> Option<&JsComputedMemberExpression> {
        match &self {
            Self::JsComputedMemberExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_conditional_expression(&self) -> Option<&JsConditionalExpression> {
        match &self {
            Self::JsConditionalExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_expression(&self) -> Option<&JsFunctionExpression> {
        match &self {
            Self::JsFunctionExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_identifier_expression(&self) -> Option<&JsIdentifierExpression> {
        match &self {
            Self::JsIdentifierExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import_call_expression(&self) -> Option<&JsImportCallExpression> {
        match &self {
            Self::JsImportCallExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import_meta_expression(&self) -> Option<&JsImportMetaExpression> {
        match &self {
            Self::JsImportMetaExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_in_expression(&self) -> Option<&JsInExpression> {
        match &self {
            Self::JsInExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_instanceof_expression(&self) -> Option<&JsInstanceofExpression> {
        match &self {
            Self::JsInstanceofExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_logical_expression(&self) -> Option<&JsLogicalExpression> {
        match &self {
            Self::JsLogicalExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_new_expression(&self) -> Option<&JsNewExpression> {
        match &self {
            Self::JsNewExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_new_target_expression(&self) -> Option<&JsNewTargetExpression> {
        match &self {
            Self::JsNewTargetExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_expression(&self) -> Option<&JsObjectExpression> {
        match &self {
            Self::JsObjectExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_parenthesized_expression(&self) -> Option<&JsParenthesizedExpression> {
        match &self {
            Self::JsParenthesizedExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_post_update_expression(&self) -> Option<&JsPostUpdateExpression> {
        match &self {
            Self::JsPostUpdateExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_pre_update_expression(&self) -> Option<&JsPreUpdateExpression> {
        match &self {
            Self::JsPreUpdateExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_sequence_expression(&self) -> Option<&JsSequenceExpression> {
        match &self {
            Self::JsSequenceExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_member_expression(&self) -> Option<&JsStaticMemberExpression> {
        match &self {
            Self::JsStaticMemberExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_super_expression(&self) -> Option<&JsSuperExpression> {
        match &self {
            Self::JsSuperExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_template_expression(&self) -> Option<&JsTemplateExpression> {
        match &self {
            Self::JsTemplateExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_this_expression(&self) -> Option<&JsThisExpression> {
        match &self {
            Self::JsThisExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_unary_expression(&self) -> Option<&JsUnaryExpression> {
        match &self {
            Self::JsUnaryExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_yield_expression(&self) -> Option<&JsYieldExpression> {
        match &self {
            Self::JsYieldExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_tag_expression(&self) -> Option<&JsxTagExpression> {
        match &self {
            Self::JsxTagExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_as_expression(&self) -> Option<&TsAsExpression> {
        match &self {
            Self::TsAsExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_instantiation_expression(&self) -> Option<&TsInstantiationExpression> {
        match &self {
            Self::TsInstantiationExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_non_null_assertion_expression(&self) -> Option<&TsNonNullAssertionExpression> {
        match &self {
            Self::TsNonNullAssertionExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_satisfies_expression(&self) -> Option<&TsSatisfiesExpression> {
        match &self {
            Self::TsSatisfiesExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_assertion_expression(&self) -> Option<&TsTypeAssertionExpression> {
        match &self {
            Self::TsTypeAssertionExpression(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsForInOrOfInitializer {
    AnyJsAssignmentPattern(AnyJsAssignmentPattern),
    JsForVariableDeclaration(JsForVariableDeclaration),
}
impl AnyJsForInOrOfInitializer {
    pub fn as_any_js_assignment_pattern(&self) -> Option<&AnyJsAssignmentPattern> {
        match &self {
            Self::AnyJsAssignmentPattern(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_for_variable_declaration(&self) -> Option<&JsForVariableDeclaration> {
        match &self {
            Self::JsForVariableDeclaration(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsForInitializer {
    AnyJsExpression(AnyJsExpression),
    JsVariableDeclaration(JsVariableDeclaration),
}
impl AnyJsForInitializer {
    pub fn as_any_js_expression(&self) -> Option<&AnyJsExpression> {
        match &self {
            Self::AnyJsExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_variable_declaration(&self) -> Option<&JsVariableDeclaration> {
        match &self {
            Self::JsVariableDeclaration(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsFormalParameter {
    JsBogusParameter(JsBogusParameter),
    JsFormalParameter(JsFormalParameter),
    JsMetavariable(JsMetavariable),
}
impl AnyJsFormalParameter {
    pub fn as_js_bogus_parameter(&self) -> Option<&JsBogusParameter> {
        match &self {
            Self::JsBogusParameter(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_formal_parameter(&self) -> Option<&JsFormalParameter> {
        match &self {
            Self::JsFormalParameter(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsFunction {
    JsArrowFunctionExpression(JsArrowFunctionExpression),
    JsFunctionDeclaration(JsFunctionDeclaration),
    JsFunctionExportDefaultDeclaration(JsFunctionExportDefaultDeclaration),
    JsFunctionExpression(JsFunctionExpression),
}
impl AnyJsFunction {
    pub fn as_js_arrow_function_expression(&self) -> Option<&JsArrowFunctionExpression> {
        match &self {
            Self::JsArrowFunctionExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_declaration(&self) -> Option<&JsFunctionDeclaration> {
        match &self {
            Self::JsFunctionDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_export_default_declaration(
        &self,
    ) -> Option<&JsFunctionExportDefaultDeclaration> {
        match &self {
            Self::JsFunctionExportDefaultDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_expression(&self) -> Option<&JsFunctionExpression> {
        match &self {
            Self::JsFunctionExpression(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsFunctionBody {
    AnyJsExpression(AnyJsExpression),
    JsFunctionBody(JsFunctionBody),
}
impl AnyJsFunctionBody {
    pub fn as_any_js_expression(&self) -> Option<&AnyJsExpression> {
        match &self {
            Self::AnyJsExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_body(&self) -> Option<&JsFunctionBody> {
        match &self {
            Self::JsFunctionBody(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsImportAssertionEntry {
    JsBogusImportAssertionEntry(JsBogusImportAssertionEntry),
    JsImportAssertionEntry(JsImportAssertionEntry),
}
impl AnyJsImportAssertionEntry {
    pub fn as_js_bogus_import_assertion_entry(&self) -> Option<&JsBogusImportAssertionEntry> {
        match &self {
            Self::JsBogusImportAssertionEntry(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import_assertion_entry(&self) -> Option<&JsImportAssertionEntry> {
        match &self {
            Self::JsImportAssertionEntry(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsImportClause {
    JsImportBareClause(JsImportBareClause),
    JsImportCombinedClause(JsImportCombinedClause),
    JsImportDefaultClause(JsImportDefaultClause),
    JsImportNamedClause(JsImportNamedClause),
    JsImportNamespaceClause(JsImportNamespaceClause),
}
impl AnyJsImportClause {
    pub fn as_js_import_bare_clause(&self) -> Option<&JsImportBareClause> {
        match &self {
            Self::JsImportBareClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import_combined_clause(&self) -> Option<&JsImportCombinedClause> {
        match &self {
            Self::JsImportCombinedClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import_default_clause(&self) -> Option<&JsImportDefaultClause> {
        match &self {
            Self::JsImportDefaultClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import_named_clause(&self) -> Option<&JsImportNamedClause> {
        match &self {
            Self::JsImportNamedClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import_namespace_clause(&self) -> Option<&JsImportNamespaceClause> {
        match &self {
            Self::JsImportNamespaceClause(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsInProperty {
    AnyJsExpression(AnyJsExpression),
    JsPrivateName(JsPrivateName),
}
impl AnyJsInProperty {
    pub fn as_any_js_expression(&self) -> Option<&AnyJsExpression> {
        match &self {
            Self::AnyJsExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_private_name(&self) -> Option<&JsPrivateName> {
        match &self {
            Self::JsPrivateName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsLiteralExpression {
    JsBigintLiteralExpression(JsBigintLiteralExpression),
    JsBooleanLiteralExpression(JsBooleanLiteralExpression),
    JsNullLiteralExpression(JsNullLiteralExpression),
    JsNumberLiteralExpression(JsNumberLiteralExpression),
    JsRegexLiteralExpression(JsRegexLiteralExpression),
    JsStringLiteralExpression(JsStringLiteralExpression),
}
impl AnyJsLiteralExpression {
    pub fn as_js_bigint_literal_expression(&self) -> Option<&JsBigintLiteralExpression> {
        match &self {
            Self::JsBigintLiteralExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_boolean_literal_expression(&self) -> Option<&JsBooleanLiteralExpression> {
        match &self {
            Self::JsBooleanLiteralExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_null_literal_expression(&self) -> Option<&JsNullLiteralExpression> {
        match &self {
            Self::JsNullLiteralExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_number_literal_expression(&self) -> Option<&JsNumberLiteralExpression> {
        match &self {
            Self::JsNumberLiteralExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_regex_literal_expression(&self) -> Option<&JsRegexLiteralExpression> {
        match &self {
            Self::JsRegexLiteralExpression(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_string_literal_expression(&self) -> Option<&JsStringLiteralExpression> {
        match &self {
            Self::JsStringLiteralExpression(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsMethodModifier {
    JsDecorator(JsDecorator),
    JsStaticModifier(JsStaticModifier),
    TsAccessibilityModifier(TsAccessibilityModifier),
    TsOverrideModifier(TsOverrideModifier),
}
impl AnyJsMethodModifier {
    pub fn as_js_decorator(&self) -> Option<&JsDecorator> {
        match &self {
            Self::JsDecorator(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_modifier(&self) -> Option<&JsStaticModifier> {
        match &self {
            Self::JsStaticModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_accessibility_modifier(&self) -> Option<&TsAccessibilityModifier> {
        match &self {
            Self::TsAccessibilityModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_override_modifier(&self) -> Option<&TsOverrideModifier> {
        match &self {
            Self::TsOverrideModifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsModuleItem {
    AnyJsStatement(AnyJsStatement),
    JsExport(JsExport),
    JsImport(JsImport),
}
impl AnyJsModuleItem {
    pub fn as_any_js_statement(&self) -> Option<&AnyJsStatement> {
        match &self {
            Self::AnyJsStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_export(&self) -> Option<&JsExport> {
        match &self {
            Self::JsExport(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_import(&self) -> Option<&JsImport> {
        match &self {
            Self::JsImport(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsModuleSource {
    JsMetavariable(JsMetavariable),
    JsModuleSource(JsModuleSource),
}
impl AnyJsModuleSource {
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_module_source(&self) -> Option<&JsModuleSource> {
        match &self {
            Self::JsModuleSource(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsName {
    JsMetavariable(JsMetavariable),
    JsName(JsName),
    JsPrivateName(JsPrivateName),
}
impl AnyJsName {
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_name(&self) -> Option<&JsName> {
        match &self {
            Self::JsName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_private_name(&self) -> Option<&JsPrivateName> {
        match &self {
            Self::JsPrivateName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsNamedImportSpecifier {
    JsBogusNamedImportSpecifier(JsBogusNamedImportSpecifier),
    JsNamedImportSpecifier(JsNamedImportSpecifier),
    JsShorthandNamedImportSpecifier(JsShorthandNamedImportSpecifier),
}
impl AnyJsNamedImportSpecifier {
    pub fn as_js_bogus_named_import_specifier(&self) -> Option<&JsBogusNamedImportSpecifier> {
        match &self {
            Self::JsBogusNamedImportSpecifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_named_import_specifier(&self) -> Option<&JsNamedImportSpecifier> {
        match &self {
            Self::JsNamedImportSpecifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_shorthand_named_import_specifier(
        &self,
    ) -> Option<&JsShorthandNamedImportSpecifier> {
        match &self {
            Self::JsShorthandNamedImportSpecifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsObjectAssignmentPatternMember {
    JsBogusAssignment(JsBogusAssignment),
    JsObjectAssignmentPatternProperty(JsObjectAssignmentPatternProperty),
    JsObjectAssignmentPatternRest(JsObjectAssignmentPatternRest),
    JsObjectAssignmentPatternShorthandProperty(JsObjectAssignmentPatternShorthandProperty),
}
impl AnyJsObjectAssignmentPatternMember {
    pub fn as_js_bogus_assignment(&self) -> Option<&JsBogusAssignment> {
        match &self {
            Self::JsBogusAssignment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_assignment_pattern_property(
        &self,
    ) -> Option<&JsObjectAssignmentPatternProperty> {
        match &self {
            Self::JsObjectAssignmentPatternProperty(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_assignment_pattern_rest(&self) -> Option<&JsObjectAssignmentPatternRest> {
        match &self {
            Self::JsObjectAssignmentPatternRest(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_assignment_pattern_shorthand_property(
        &self,
    ) -> Option<&JsObjectAssignmentPatternShorthandProperty> {
        match &self {
            Self::JsObjectAssignmentPatternShorthandProperty(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsObjectBindingPatternMember {
    JsBogusBinding(JsBogusBinding),
    JsMetavariable(JsMetavariable),
    JsObjectBindingPatternProperty(JsObjectBindingPatternProperty),
    JsObjectBindingPatternRest(JsObjectBindingPatternRest),
    JsObjectBindingPatternShorthandProperty(JsObjectBindingPatternShorthandProperty),
}
impl AnyJsObjectBindingPatternMember {
    pub fn as_js_bogus_binding(&self) -> Option<&JsBogusBinding> {
        match &self {
            Self::JsBogusBinding(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_binding_pattern_property(&self) -> Option<&JsObjectBindingPatternProperty> {
        match &self {
            Self::JsObjectBindingPatternProperty(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_binding_pattern_rest(&self) -> Option<&JsObjectBindingPatternRest> {
        match &self {
            Self::JsObjectBindingPatternRest(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_object_binding_pattern_shorthand_property(
        &self,
    ) -> Option<&JsObjectBindingPatternShorthandProperty> {
        match &self {
            Self::JsObjectBindingPatternShorthandProperty(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsObjectMember {
    JsBogusMember(JsBogusMember),
    JsGetterObjectMember(JsGetterObjectMember),
    JsMetavariable(JsMetavariable),
    JsMethodObjectMember(JsMethodObjectMember),
    JsPropertyObjectMember(JsPropertyObjectMember),
    JsSetterObjectMember(JsSetterObjectMember),
    JsShorthandPropertyObjectMember(JsShorthandPropertyObjectMember),
    JsSpread(JsSpread),
}
impl AnyJsObjectMember {
    pub fn as_js_bogus_member(&self) -> Option<&JsBogusMember> {
        match &self {
            Self::JsBogusMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_getter_object_member(&self) -> Option<&JsGetterObjectMember> {
        match &self {
            Self::JsGetterObjectMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_method_object_member(&self) -> Option<&JsMethodObjectMember> {
        match &self {
            Self::JsMethodObjectMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_property_object_member(&self) -> Option<&JsPropertyObjectMember> {
        match &self {
            Self::JsPropertyObjectMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_setter_object_member(&self) -> Option<&JsSetterObjectMember> {
        match &self {
            Self::JsSetterObjectMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_shorthand_property_object_member(
        &self,
    ) -> Option<&JsShorthandPropertyObjectMember> {
        match &self {
            Self::JsShorthandPropertyObjectMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_spread(&self) -> Option<&JsSpread> {
        match &self {
            Self::JsSpread(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsObjectMemberName {
    JsComputedMemberName(JsComputedMemberName),
    JsLiteralMemberName(JsLiteralMemberName),
    JsMetavariable(JsMetavariable),
}
impl AnyJsObjectMemberName {
    pub fn as_js_computed_member_name(&self) -> Option<&JsComputedMemberName> {
        match &self {
            Self::JsComputedMemberName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_literal_member_name(&self) -> Option<&JsLiteralMemberName> {
        match &self {
            Self::JsLiteralMemberName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsParameter {
    AnyJsFormalParameter(AnyJsFormalParameter),
    JsRestParameter(JsRestParameter),
    TsThisParameter(TsThisParameter),
}
impl AnyJsParameter {
    pub fn as_any_js_formal_parameter(&self) -> Option<&AnyJsFormalParameter> {
        match &self {
            Self::AnyJsFormalParameter(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_rest_parameter(&self) -> Option<&JsRestParameter> {
        match &self {
            Self::JsRestParameter(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_this_parameter(&self) -> Option<&TsThisParameter> {
        match &self {
            Self::TsThisParameter(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsPropertyModifier {
    JsAccessorModifier(JsAccessorModifier),
    JsDecorator(JsDecorator),
    JsStaticModifier(JsStaticModifier),
    TsAccessibilityModifier(TsAccessibilityModifier),
    TsOverrideModifier(TsOverrideModifier),
    TsReadonlyModifier(TsReadonlyModifier),
}
impl AnyJsPropertyModifier {
    pub fn as_js_accessor_modifier(&self) -> Option<&JsAccessorModifier> {
        match &self {
            Self::JsAccessorModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_decorator(&self) -> Option<&JsDecorator> {
        match &self {
            Self::JsDecorator(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_modifier(&self) -> Option<&JsStaticModifier> {
        match &self {
            Self::JsStaticModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_accessibility_modifier(&self) -> Option<&TsAccessibilityModifier> {
        match &self {
            Self::TsAccessibilityModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_override_modifier(&self) -> Option<&TsOverrideModifier> {
        match &self {
            Self::TsOverrideModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_readonly_modifier(&self) -> Option<&TsReadonlyModifier> {
        match &self {
            Self::TsReadonlyModifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsRoot {
    JsExpressionSnipped(JsExpressionSnipped),
    JsModule(JsModule),
    JsScript(JsScript),
    TsDeclarationModule(TsDeclarationModule),
}
impl AnyJsRoot {
    pub fn as_js_expression_snipped(&self) -> Option<&JsExpressionSnipped> {
        match &self {
            Self::JsExpressionSnipped(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_module(&self) -> Option<&JsModule> {
        match &self {
            Self::JsModule(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_script(&self) -> Option<&JsScript> {
        match &self {
            Self::JsScript(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_declaration_module(&self) -> Option<&TsDeclarationModule> {
        match &self {
            Self::TsDeclarationModule(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsStatement {
    JsBlockStatement(JsBlockStatement),
    JsBogusStatement(JsBogusStatement),
    JsBreakStatement(JsBreakStatement),
    JsClassDeclaration(JsClassDeclaration),
    JsContinueStatement(JsContinueStatement),
    JsDebuggerStatement(JsDebuggerStatement),
    JsDoWhileStatement(JsDoWhileStatement),
    JsEmptyStatement(JsEmptyStatement),
    JsExpressionStatement(JsExpressionStatement),
    JsForInStatement(JsForInStatement),
    JsForOfStatement(JsForOfStatement),
    JsForStatement(JsForStatement),
    JsFunctionDeclaration(JsFunctionDeclaration),
    JsIfStatement(JsIfStatement),
    JsLabeledStatement(JsLabeledStatement),
    JsMetavariable(JsMetavariable),
    JsReturnStatement(JsReturnStatement),
    JsSwitchStatement(JsSwitchStatement),
    JsThrowStatement(JsThrowStatement),
    JsTryFinallyStatement(JsTryFinallyStatement),
    JsTryStatement(JsTryStatement),
    JsVariableStatement(JsVariableStatement),
    JsWhileStatement(JsWhileStatement),
    JsWithStatement(JsWithStatement),
    TsDeclareFunctionDeclaration(TsDeclareFunctionDeclaration),
    TsDeclareStatement(TsDeclareStatement),
    TsEnumDeclaration(TsEnumDeclaration),
    TsExternalModuleDeclaration(TsExternalModuleDeclaration),
    TsGlobalDeclaration(TsGlobalDeclaration),
    TsImportEqualsDeclaration(TsImportEqualsDeclaration),
    TsInterfaceDeclaration(TsInterfaceDeclaration),
    TsModuleDeclaration(TsModuleDeclaration),
    TsTypeAliasDeclaration(TsTypeAliasDeclaration),
}
impl AnyJsStatement {
    pub fn as_js_block_statement(&self) -> Option<&JsBlockStatement> {
        match &self {
            Self::JsBlockStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_bogus_statement(&self) -> Option<&JsBogusStatement> {
        match &self {
            Self::JsBogusStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_break_statement(&self) -> Option<&JsBreakStatement> {
        match &self {
            Self::JsBreakStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_class_declaration(&self) -> Option<&JsClassDeclaration> {
        match &self {
            Self::JsClassDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_continue_statement(&self) -> Option<&JsContinueStatement> {
        match &self {
            Self::JsContinueStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_debugger_statement(&self) -> Option<&JsDebuggerStatement> {
        match &self {
            Self::JsDebuggerStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_do_while_statement(&self) -> Option<&JsDoWhileStatement> {
        match &self {
            Self::JsDoWhileStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_empty_statement(&self) -> Option<&JsEmptyStatement> {
        match &self {
            Self::JsEmptyStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_expression_statement(&self) -> Option<&JsExpressionStatement> {
        match &self {
            Self::JsExpressionStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_for_in_statement(&self) -> Option<&JsForInStatement> {
        match &self {
            Self::JsForInStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_for_of_statement(&self) -> Option<&JsForOfStatement> {
        match &self {
            Self::JsForOfStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_for_statement(&self) -> Option<&JsForStatement> {
        match &self {
            Self::JsForStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_function_declaration(&self) -> Option<&JsFunctionDeclaration> {
        match &self {
            Self::JsFunctionDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_if_statement(&self) -> Option<&JsIfStatement> {
        match &self {
            Self::JsIfStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_labeled_statement(&self) -> Option<&JsLabeledStatement> {
        match &self {
            Self::JsLabeledStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_return_statement(&self) -> Option<&JsReturnStatement> {
        match &self {
            Self::JsReturnStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_switch_statement(&self) -> Option<&JsSwitchStatement> {
        match &self {
            Self::JsSwitchStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_throw_statement(&self) -> Option<&JsThrowStatement> {
        match &self {
            Self::JsThrowStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_try_finally_statement(&self) -> Option<&JsTryFinallyStatement> {
        match &self {
            Self::JsTryFinallyStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_try_statement(&self) -> Option<&JsTryStatement> {
        match &self {
            Self::JsTryStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_variable_statement(&self) -> Option<&JsVariableStatement> {
        match &self {
            Self::JsVariableStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_while_statement(&self) -> Option<&JsWhileStatement> {
        match &self {
            Self::JsWhileStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_with_statement(&self) -> Option<&JsWithStatement> {
        match &self {
            Self::JsWithStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_declare_function_declaration(&self) -> Option<&TsDeclareFunctionDeclaration> {
        match &self {
            Self::TsDeclareFunctionDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_declare_statement(&self) -> Option<&TsDeclareStatement> {
        match &self {
            Self::TsDeclareStatement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_enum_declaration(&self) -> Option<&TsEnumDeclaration> {
        match &self {
            Self::TsEnumDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_external_module_declaration(&self) -> Option<&TsExternalModuleDeclaration> {
        match &self {
            Self::TsExternalModuleDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_global_declaration(&self) -> Option<&TsGlobalDeclaration> {
        match &self {
            Self::TsGlobalDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_import_equals_declaration(&self) -> Option<&TsImportEqualsDeclaration> {
        match &self {
            Self::TsImportEqualsDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_interface_declaration(&self) -> Option<&TsInterfaceDeclaration> {
        match &self {
            Self::TsInterfaceDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_module_declaration(&self) -> Option<&TsModuleDeclaration> {
        match &self {
            Self::TsModuleDeclaration(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_alias_declaration(&self) -> Option<&TsTypeAliasDeclaration> {
        match &self {
            Self::TsTypeAliasDeclaration(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsSwitchClause {
    JsCaseClause(JsCaseClause),
    JsDefaultClause(JsDefaultClause),
}
impl AnyJsSwitchClause {
    pub fn as_js_case_clause(&self) -> Option<&JsCaseClause> {
        match &self {
            Self::JsCaseClause(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_default_clause(&self) -> Option<&JsDefaultClause> {
        match &self {
            Self::JsDefaultClause(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsTemplateElement {
    JsTemplateChunkElement(JsTemplateChunkElement),
    JsTemplateElement(JsTemplateElement),
}
impl AnyJsTemplateElement {
    pub fn as_js_template_chunk_element(&self) -> Option<&JsTemplateChunkElement> {
        match &self {
            Self::JsTemplateChunkElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_template_element(&self) -> Option<&JsTemplateElement> {
        match &self {
            Self::JsTemplateElement(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxAttribute {
    JsMetavariable(JsMetavariable),
    JsxAttribute(JsxAttribute),
    JsxSpreadAttribute(JsxSpreadAttribute),
}
impl AnyJsxAttribute {
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_attribute(&self) -> Option<&JsxAttribute> {
        match &self {
            Self::JsxAttribute(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_spread_attribute(&self) -> Option<&JsxSpreadAttribute> {
        match &self {
            Self::JsxSpreadAttribute(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxAttributeName {
    JsxName(JsxName),
    JsxNamespaceName(JsxNamespaceName),
}
impl AnyJsxAttributeName {
    pub fn as_jsx_name(&self) -> Option<&JsxName> {
        match &self {
            Self::JsxName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_namespace_name(&self) -> Option<&JsxNamespaceName> {
        match &self {
            Self::JsxNamespaceName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxAttributeValue {
    AnyJsxTag(AnyJsxTag),
    JsxExpressionAttributeValue(JsxExpressionAttributeValue),
    JsxString(JsxString),
}
impl AnyJsxAttributeValue {
    pub fn as_any_jsx_tag(&self) -> Option<&AnyJsxTag> {
        match &self {
            Self::AnyJsxTag(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_expression_attribute_value(&self) -> Option<&JsxExpressionAttributeValue> {
        match &self {
            Self::JsxExpressionAttributeValue(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_string(&self) -> Option<&JsxString> {
        match &self {
            Self::JsxString(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxChild {
    JsMetavariable(JsMetavariable),
    JsxElement(JsxElement),
    JsxExpressionChild(JsxExpressionChild),
    JsxFragment(JsxFragment),
    JsxSelfClosingElement(JsxSelfClosingElement),
    JsxSpreadChild(JsxSpreadChild),
    JsxText(JsxText),
}
impl AnyJsxChild {
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_element(&self) -> Option<&JsxElement> {
        match &self {
            Self::JsxElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_expression_child(&self) -> Option<&JsxExpressionChild> {
        match &self {
            Self::JsxExpressionChild(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_fragment(&self) -> Option<&JsxFragment> {
        match &self {
            Self::JsxFragment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_self_closing_element(&self) -> Option<&JsxSelfClosingElement> {
        match &self {
            Self::JsxSelfClosingElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_spread_child(&self) -> Option<&JsxSpreadChild> {
        match &self {
            Self::JsxSpreadChild(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_text(&self) -> Option<&JsxText> {
        match &self {
            Self::JsxText(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxElementName {
    JsMetavariable(JsMetavariable),
    JsxMemberName(JsxMemberName),
    JsxName(JsxName),
    JsxNamespaceName(JsxNamespaceName),
    JsxReferenceIdentifier(JsxReferenceIdentifier),
}
impl AnyJsxElementName {
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_member_name(&self) -> Option<&JsxMemberName> {
        match &self {
            Self::JsxMemberName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_name(&self) -> Option<&JsxName> {
        match &self {
            Self::JsxName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_namespace_name(&self) -> Option<&JsxNamespaceName> {
        match &self {
            Self::JsxNamespaceName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_reference_identifier(&self) -> Option<&JsxReferenceIdentifier> {
        match &self {
            Self::JsxReferenceIdentifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxName {
    JsxName(JsxName),
    JsxNamespaceName(JsxNamespaceName),
}
impl AnyJsxName {
    pub fn as_jsx_name(&self) -> Option<&JsxName> {
        match &self {
            Self::JsxName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_namespace_name(&self) -> Option<&JsxNamespaceName> {
        match &self {
            Self::JsxNamespaceName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxObjectName {
    JsxMemberName(JsxMemberName),
    JsxNamespaceName(JsxNamespaceName),
    JsxReferenceIdentifier(JsxReferenceIdentifier),
}
impl AnyJsxObjectName {
    pub fn as_jsx_member_name(&self) -> Option<&JsxMemberName> {
        match &self {
            Self::JsxMemberName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_namespace_name(&self) -> Option<&JsxNamespaceName> {
        match &self {
            Self::JsxNamespaceName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_reference_identifier(&self) -> Option<&JsxReferenceIdentifier> {
        match &self {
            Self::JsxReferenceIdentifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyJsxTag {
    JsxElement(JsxElement),
    JsxFragment(JsxFragment),
    JsxSelfClosingElement(JsxSelfClosingElement),
}
impl AnyJsxTag {
    pub fn as_jsx_element(&self) -> Option<&JsxElement> {
        match &self {
            Self::JsxElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_fragment(&self) -> Option<&JsxFragment> {
        match &self {
            Self::JsxFragment(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_jsx_self_closing_element(&self) -> Option<&JsxSelfClosingElement> {
        match &self {
            Self::JsxSelfClosingElement(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsEnumMemberName {
    JsComputedMemberName(JsComputedMemberName),
    TsLiteralEnumMemberName(TsLiteralEnumMemberName),
}
impl AnyTsEnumMemberName {
    pub fn as_js_computed_member_name(&self) -> Option<&JsComputedMemberName> {
        match &self {
            Self::JsComputedMemberName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_literal_enum_member_name(&self) -> Option<&TsLiteralEnumMemberName> {
        match &self {
            Self::TsLiteralEnumMemberName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsExternalModuleDeclarationBody {
    TsEmptyExternalModuleDeclarationBody(TsEmptyExternalModuleDeclarationBody),
    TsModuleBlock(TsModuleBlock),
}
impl AnyTsExternalModuleDeclarationBody {
    pub fn as_ts_empty_external_module_declaration_body(
        &self,
    ) -> Option<&TsEmptyExternalModuleDeclarationBody> {
        match &self {
            Self::TsEmptyExternalModuleDeclarationBody(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_module_block(&self) -> Option<&TsModuleBlock> {
        match &self {
            Self::TsModuleBlock(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsIdentifierBinding {
    JsMetavariable(JsMetavariable),
    TsIdentifierBinding(TsIdentifierBinding),
}
impl AnyTsIdentifierBinding {
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_identifier_binding(&self) -> Option<&TsIdentifierBinding> {
        match &self {
            Self::TsIdentifierBinding(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsIndexSignatureModifier {
    JsStaticModifier(JsStaticModifier),
    TsReadonlyModifier(TsReadonlyModifier),
}
impl AnyTsIndexSignatureModifier {
    pub fn as_js_static_modifier(&self) -> Option<&JsStaticModifier> {
        match &self {
            Self::JsStaticModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_readonly_modifier(&self) -> Option<&TsReadonlyModifier> {
        match &self {
            Self::TsReadonlyModifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsMethodSignatureModifier {
    JsDecorator(JsDecorator),
    JsStaticModifier(JsStaticModifier),
    TsAbstractModifier(TsAbstractModifier),
    TsAccessibilityModifier(TsAccessibilityModifier),
    TsOverrideModifier(TsOverrideModifier),
}
impl AnyTsMethodSignatureModifier {
    pub fn as_js_decorator(&self) -> Option<&JsDecorator> {
        match &self {
            Self::JsDecorator(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_modifier(&self) -> Option<&JsStaticModifier> {
        match &self {
            Self::JsStaticModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_abstract_modifier(&self) -> Option<&TsAbstractModifier> {
        match &self {
            Self::TsAbstractModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_accessibility_modifier(&self) -> Option<&TsAccessibilityModifier> {
        match &self {
            Self::TsAccessibilityModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_override_modifier(&self) -> Option<&TsOverrideModifier> {
        match &self {
            Self::TsOverrideModifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsModuleName {
    AnyTsIdentifierBinding(AnyTsIdentifierBinding),
    TsQualifiedModuleName(TsQualifiedModuleName),
}
impl AnyTsModuleName {
    pub fn as_any_ts_identifier_binding(&self) -> Option<&AnyTsIdentifierBinding> {
        match &self {
            Self::AnyTsIdentifierBinding(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_qualified_module_name(&self) -> Option<&TsQualifiedModuleName> {
        match &self {
            Self::TsQualifiedModuleName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsModuleReference {
    AnyTsName(AnyTsName),
    TsExternalModuleReference(TsExternalModuleReference),
}
impl AnyTsModuleReference {
    pub fn as_any_ts_name(&self) -> Option<&AnyTsName> {
        match &self {
            Self::AnyTsName(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_external_module_reference(&self) -> Option<&TsExternalModuleReference> {
        match &self {
            Self::TsExternalModuleReference(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsName {
    JsReferenceIdentifier(JsReferenceIdentifier),
    TsQualifiedName(TsQualifiedName),
}
impl AnyTsName {
    pub fn as_js_reference_identifier(&self) -> Option<&JsReferenceIdentifier> {
        match &self {
            Self::JsReferenceIdentifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_qualified_name(&self) -> Option<&TsQualifiedName> {
        match &self {
            Self::TsQualifiedName(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsPropertyAnnotation {
    TsDefinitePropertyAnnotation(TsDefinitePropertyAnnotation),
    TsOptionalPropertyAnnotation(TsOptionalPropertyAnnotation),
    TsTypeAnnotation(TsTypeAnnotation),
}
impl AnyTsPropertyAnnotation {
    pub fn as_ts_definite_property_annotation(&self) -> Option<&TsDefinitePropertyAnnotation> {
        match &self {
            Self::TsDefinitePropertyAnnotation(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_optional_property_annotation(&self) -> Option<&TsOptionalPropertyAnnotation> {
        match &self {
            Self::TsOptionalPropertyAnnotation(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_annotation(&self) -> Option<&TsTypeAnnotation> {
        match &self {
            Self::TsTypeAnnotation(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsPropertyParameterModifier {
    TsAccessibilityModifier(TsAccessibilityModifier),
    TsOverrideModifier(TsOverrideModifier),
    TsReadonlyModifier(TsReadonlyModifier),
}
impl AnyTsPropertyParameterModifier {
    pub fn as_ts_accessibility_modifier(&self) -> Option<&TsAccessibilityModifier> {
        match &self {
            Self::TsAccessibilityModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_override_modifier(&self) -> Option<&TsOverrideModifier> {
        match &self {
            Self::TsOverrideModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_readonly_modifier(&self) -> Option<&TsReadonlyModifier> {
        match &self {
            Self::TsReadonlyModifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsPropertySignatureAnnotation {
    TsOptionalPropertyAnnotation(TsOptionalPropertyAnnotation),
    TsTypeAnnotation(TsTypeAnnotation),
}
impl AnyTsPropertySignatureAnnotation {
    pub fn as_ts_optional_property_annotation(&self) -> Option<&TsOptionalPropertyAnnotation> {
        match &self {
            Self::TsOptionalPropertyAnnotation(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_annotation(&self) -> Option<&TsTypeAnnotation> {
        match &self {
            Self::TsTypeAnnotation(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsPropertySignatureModifier {
    JsAccessorModifier(JsAccessorModifier),
    JsDecorator(JsDecorator),
    JsStaticModifier(JsStaticModifier),
    TsAbstractModifier(TsAbstractModifier),
    TsAccessibilityModifier(TsAccessibilityModifier),
    TsDeclareModifier(TsDeclareModifier),
    TsOverrideModifier(TsOverrideModifier),
    TsReadonlyModifier(TsReadonlyModifier),
}
impl AnyTsPropertySignatureModifier {
    pub fn as_js_accessor_modifier(&self) -> Option<&JsAccessorModifier> {
        match &self {
            Self::JsAccessorModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_decorator(&self) -> Option<&JsDecorator> {
        match &self {
            Self::JsDecorator(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_js_static_modifier(&self) -> Option<&JsStaticModifier> {
        match &self {
            Self::JsStaticModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_abstract_modifier(&self) -> Option<&TsAbstractModifier> {
        match &self {
            Self::TsAbstractModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_accessibility_modifier(&self) -> Option<&TsAccessibilityModifier> {
        match &self {
            Self::TsAccessibilityModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_declare_modifier(&self) -> Option<&TsDeclareModifier> {
        match &self {
            Self::TsDeclareModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_override_modifier(&self) -> Option<&TsOverrideModifier> {
        match &self {
            Self::TsOverrideModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_readonly_modifier(&self) -> Option<&TsReadonlyModifier> {
        match &self {
            Self::TsReadonlyModifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsReturnType {
    AnyTsType(AnyTsType),
    TsAssertsReturnType(TsAssertsReturnType),
    TsPredicateReturnType(TsPredicateReturnType),
}
impl AnyTsReturnType {
    pub fn as_any_ts_type(&self) -> Option<&AnyTsType> {
        match &self {
            Self::AnyTsType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_asserts_return_type(&self) -> Option<&TsAssertsReturnType> {
        match &self {
            Self::TsAssertsReturnType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_predicate_return_type(&self) -> Option<&TsPredicateReturnType> {
        match &self {
            Self::TsPredicateReturnType(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsTemplateElement {
    TsTemplateChunkElement(TsTemplateChunkElement),
    TsTemplateElement(TsTemplateElement),
}
impl AnyTsTemplateElement {
    pub fn as_ts_template_chunk_element(&self) -> Option<&TsTemplateChunkElement> {
        match &self {
            Self::TsTemplateChunkElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_template_element(&self) -> Option<&TsTemplateElement> {
        match &self {
            Self::TsTemplateElement(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsTupleTypeElement {
    AnyTsType(AnyTsType),
    TsNamedTupleTypeElement(TsNamedTupleTypeElement),
    TsOptionalTupleTypeElement(TsOptionalTupleTypeElement),
    TsRestTupleTypeElement(TsRestTupleTypeElement),
}
impl AnyTsTupleTypeElement {
    pub fn as_any_ts_type(&self) -> Option<&AnyTsType> {
        match &self {
            Self::AnyTsType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_named_tuple_type_element(&self) -> Option<&TsNamedTupleTypeElement> {
        match &self {
            Self::TsNamedTupleTypeElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_optional_tuple_type_element(&self) -> Option<&TsOptionalTupleTypeElement> {
        match &self {
            Self::TsOptionalTupleTypeElement(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_rest_tuple_type_element(&self) -> Option<&TsRestTupleTypeElement> {
        match &self {
            Self::TsRestTupleTypeElement(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsType {
    JsMetavariable(JsMetavariable),
    TsAnyType(TsAnyType),
    TsArrayType(TsArrayType),
    TsBigintLiteralType(TsBigintLiteralType),
    TsBigintType(TsBigintType),
    TsBogusType(TsBogusType),
    TsBooleanLiteralType(TsBooleanLiteralType),
    TsBooleanType(TsBooleanType),
    TsConditionalType(TsConditionalType),
    TsConstructorType(TsConstructorType),
    TsFunctionType(TsFunctionType),
    TsImportType(TsImportType),
    TsIndexedAccessType(TsIndexedAccessType),
    TsInferType(TsInferType),
    TsIntersectionType(TsIntersectionType),
    TsMappedType(TsMappedType),
    TsNeverType(TsNeverType),
    TsNonPrimitiveType(TsNonPrimitiveType),
    TsNullLiteralType(TsNullLiteralType),
    TsNumberLiteralType(TsNumberLiteralType),
    TsNumberType(TsNumberType),
    TsObjectType(TsObjectType),
    TsParenthesizedType(TsParenthesizedType),
    TsReferenceType(TsReferenceType),
    TsStringLiteralType(TsStringLiteralType),
    TsStringType(TsStringType),
    TsSymbolType(TsSymbolType),
    TsTemplateLiteralType(TsTemplateLiteralType),
    TsThisType(TsThisType),
    TsTupleType(TsTupleType),
    TsTypeOperatorType(TsTypeOperatorType),
    TsTypeofType(TsTypeofType),
    TsUndefinedType(TsUndefinedType),
    TsUnionType(TsUnionType),
    TsUnknownType(TsUnknownType),
    TsVoidType(TsVoidType),
}
impl AnyTsType {
    pub fn as_js_metavariable(&self) -> Option<&JsMetavariable> {
        match &self {
            Self::JsMetavariable(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_any_type(&self) -> Option<&TsAnyType> {
        match &self {
            Self::TsAnyType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_array_type(&self) -> Option<&TsArrayType> {
        match &self {
            Self::TsArrayType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_bigint_literal_type(&self) -> Option<&TsBigintLiteralType> {
        match &self {
            Self::TsBigintLiteralType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_bigint_type(&self) -> Option<&TsBigintType> {
        match &self {
            Self::TsBigintType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_bogus_type(&self) -> Option<&TsBogusType> {
        match &self {
            Self::TsBogusType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_boolean_literal_type(&self) -> Option<&TsBooleanLiteralType> {
        match &self {
            Self::TsBooleanLiteralType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_boolean_type(&self) -> Option<&TsBooleanType> {
        match &self {
            Self::TsBooleanType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_conditional_type(&self) -> Option<&TsConditionalType> {
        match &self {
            Self::TsConditionalType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_constructor_type(&self) -> Option<&TsConstructorType> {
        match &self {
            Self::TsConstructorType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_function_type(&self) -> Option<&TsFunctionType> {
        match &self {
            Self::TsFunctionType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_import_type(&self) -> Option<&TsImportType> {
        match &self {
            Self::TsImportType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_indexed_access_type(&self) -> Option<&TsIndexedAccessType> {
        match &self {
            Self::TsIndexedAccessType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_infer_type(&self) -> Option<&TsInferType> {
        match &self {
            Self::TsInferType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_intersection_type(&self) -> Option<&TsIntersectionType> {
        match &self {
            Self::TsIntersectionType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_mapped_type(&self) -> Option<&TsMappedType> {
        match &self {
            Self::TsMappedType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_never_type(&self) -> Option<&TsNeverType> {
        match &self {
            Self::TsNeverType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_non_primitive_type(&self) -> Option<&TsNonPrimitiveType> {
        match &self {
            Self::TsNonPrimitiveType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_null_literal_type(&self) -> Option<&TsNullLiteralType> {
        match &self {
            Self::TsNullLiteralType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_number_literal_type(&self) -> Option<&TsNumberLiteralType> {
        match &self {
            Self::TsNumberLiteralType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_number_type(&self) -> Option<&TsNumberType> {
        match &self {
            Self::TsNumberType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_object_type(&self) -> Option<&TsObjectType> {
        match &self {
            Self::TsObjectType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_parenthesized_type(&self) -> Option<&TsParenthesizedType> {
        match &self {
            Self::TsParenthesizedType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_reference_type(&self) -> Option<&TsReferenceType> {
        match &self {
            Self::TsReferenceType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_string_literal_type(&self) -> Option<&TsStringLiteralType> {
        match &self {
            Self::TsStringLiteralType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_string_type(&self) -> Option<&TsStringType> {
        match &self {
            Self::TsStringType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_symbol_type(&self) -> Option<&TsSymbolType> {
        match &self {
            Self::TsSymbolType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_template_literal_type(&self) -> Option<&TsTemplateLiteralType> {
        match &self {
            Self::TsTemplateLiteralType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_this_type(&self) -> Option<&TsThisType> {
        match &self {
            Self::TsThisType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_tuple_type(&self) -> Option<&TsTupleType> {
        match &self {
            Self::TsTupleType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_operator_type(&self) -> Option<&TsTypeOperatorType> {
        match &self {
            Self::TsTypeOperatorType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_typeof_type(&self) -> Option<&TsTypeofType> {
        match &self {
            Self::TsTypeofType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_undefined_type(&self) -> Option<&TsUndefinedType> {
        match &self {
            Self::TsUndefinedType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_union_type(&self) -> Option<&TsUnionType> {
        match &self {
            Self::TsUnionType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_unknown_type(&self) -> Option<&TsUnknownType> {
        match &self {
            Self::TsUnknownType(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_void_type(&self) -> Option<&TsVoidType> {
        match &self {
            Self::TsVoidType(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsTypeMember {
    JsBogusMember(JsBogusMember),
    TsCallSignatureTypeMember(TsCallSignatureTypeMember),
    TsConstructSignatureTypeMember(TsConstructSignatureTypeMember),
    TsGetterSignatureTypeMember(TsGetterSignatureTypeMember),
    TsIndexSignatureTypeMember(TsIndexSignatureTypeMember),
    TsMethodSignatureTypeMember(TsMethodSignatureTypeMember),
    TsPropertySignatureTypeMember(TsPropertySignatureTypeMember),
    TsSetterSignatureTypeMember(TsSetterSignatureTypeMember),
}
impl AnyTsTypeMember {
    pub fn as_js_bogus_member(&self) -> Option<&JsBogusMember> {
        match &self {
            Self::JsBogusMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_call_signature_type_member(&self) -> Option<&TsCallSignatureTypeMember> {
        match &self {
            Self::TsCallSignatureTypeMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_construct_signature_type_member(&self) -> Option<&TsConstructSignatureTypeMember> {
        match &self {
            Self::TsConstructSignatureTypeMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_getter_signature_type_member(&self) -> Option<&TsGetterSignatureTypeMember> {
        match &self {
            Self::TsGetterSignatureTypeMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_index_signature_type_member(&self) -> Option<&TsIndexSignatureTypeMember> {
        match &self {
            Self::TsIndexSignatureTypeMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_method_signature_type_member(&self) -> Option<&TsMethodSignatureTypeMember> {
        match &self {
            Self::TsMethodSignatureTypeMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_property_signature_type_member(&self) -> Option<&TsPropertySignatureTypeMember> {
        match &self {
            Self::TsPropertySignatureTypeMember(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_setter_signature_type_member(&self) -> Option<&TsSetterSignatureTypeMember> {
        match &self {
            Self::TsSetterSignatureTypeMember(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsTypeParameterModifier {
    TsConstModifier(TsConstModifier),
    TsInModifier(TsInModifier),
    TsOutModifier(TsOutModifier),
}
impl AnyTsTypeParameterModifier {
    pub fn as_ts_const_modifier(&self) -> Option<&TsConstModifier> {
        match &self {
            Self::TsConstModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_in_modifier(&self) -> Option<&TsInModifier> {
        match &self {
            Self::TsInModifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_out_modifier(&self) -> Option<&TsOutModifier> {
        match &self {
            Self::TsOutModifier(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsTypePredicateParameterName {
    JsReferenceIdentifier(JsReferenceIdentifier),
    TsThisType(TsThisType),
}
impl AnyTsTypePredicateParameterName {
    pub fn as_js_reference_identifier(&self) -> Option<&JsReferenceIdentifier> {
        match &self {
            Self::JsReferenceIdentifier(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_this_type(&self) -> Option<&TsThisType> {
        match &self {
            Self::TsThisType(item) => Some(item),
            _ => None,
        }
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub enum AnyTsVariableAnnotation {
    TsDefiniteVariableAnnotation(TsDefiniteVariableAnnotation),
    TsTypeAnnotation(TsTypeAnnotation),
}
impl AnyTsVariableAnnotation {
    pub fn as_ts_definite_variable_annotation(&self) -> Option<&TsDefiniteVariableAnnotation> {
        match &self {
            Self::TsDefiniteVariableAnnotation(item) => Some(item),
            _ => None,
        }
    }
    pub fn as_ts_type_annotation(&self) -> Option<&TsTypeAnnotation> {
        match &self {
            Self::TsTypeAnnotation(item) => Some(item),
            _ => None,
        }
    }
}
impl AstNode for JsAccessorModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ACCESSOR_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ACCESSOR_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsAccessorModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsAccessorModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsAccessorModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsAccessorModifier> for SyntaxNode {
    fn from(n: JsAccessorModifier) -> Self {
        n.syntax
    }
}
impl From<JsAccessorModifier> for SyntaxElement {
    fn from(n: JsAccessorModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayAssignmentPattern {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_ASSIGNMENT_PATTERN as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_ASSIGNMENT_PATTERN
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayAssignmentPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrayAssignmentPattern")
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("elements", &self.elements())
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsArrayAssignmentPattern").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrayAssignmentPattern> for SyntaxNode {
    fn from(n: JsArrayAssignmentPattern) -> Self {
        n.syntax
    }
}
impl From<JsArrayAssignmentPattern> for SyntaxElement {
    fn from(n: JsArrayAssignmentPattern) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayAssignmentPatternElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_ASSIGNMENT_PATTERN_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_ASSIGNMENT_PATTERN_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayAssignmentPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrayAssignmentPatternElement")
                .field("pattern", &support::DebugSyntaxResult(self.pattern()))
                .field("init", &support::DebugOptionalElement(self.init()))
                .finish()
        } else {
            f.debug_struct("JsArrayAssignmentPatternElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrayAssignmentPatternElement> for SyntaxNode {
    fn from(n: JsArrayAssignmentPatternElement) -> Self {
        n.syntax
    }
}
impl From<JsArrayAssignmentPatternElement> for SyntaxElement {
    fn from(n: JsArrayAssignmentPatternElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayAssignmentPatternRestElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        JS_ARRAY_ASSIGNMENT_PATTERN_REST_ELEMENT as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_ASSIGNMENT_PATTERN_REST_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayAssignmentPatternRestElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrayAssignmentPatternRestElement")
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("pattern", &support::DebugSyntaxResult(self.pattern()))
                .finish()
        } else {
            f.debug_struct("JsArrayAssignmentPatternRestElement")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrayAssignmentPatternRestElement> for SyntaxNode {
    fn from(n: JsArrayAssignmentPatternRestElement) -> Self {
        n.syntax
    }
}
impl From<JsArrayAssignmentPatternRestElement> for SyntaxElement {
    fn from(n: JsArrayAssignmentPatternRestElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayBindingPattern {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_BINDING_PATTERN as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_BINDING_PATTERN
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayBindingPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrayBindingPattern")
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("elements", &self.elements())
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsArrayBindingPattern").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrayBindingPattern> for SyntaxNode {
    fn from(n: JsArrayBindingPattern) -> Self {
        n.syntax
    }
}
impl From<JsArrayBindingPattern> for SyntaxElement {
    fn from(n: JsArrayBindingPattern) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayBindingPatternElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_BINDING_PATTERN_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_BINDING_PATTERN_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayBindingPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrayBindingPatternElement")
                .field("pattern", &support::DebugSyntaxResult(self.pattern()))
                .field("init", &support::DebugOptionalElement(self.init()))
                .finish()
        } else {
            f.debug_struct("JsArrayBindingPatternElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrayBindingPatternElement> for SyntaxNode {
    fn from(n: JsArrayBindingPatternElement) -> Self {
        n.syntax
    }
}
impl From<JsArrayBindingPatternElement> for SyntaxElement {
    fn from(n: JsArrayBindingPatternElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayBindingPatternRestElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_BINDING_PATTERN_REST_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_BINDING_PATTERN_REST_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayBindingPatternRestElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrayBindingPatternRestElement")
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("pattern", &support::DebugSyntaxResult(self.pattern()))
                .finish()
        } else {
            f.debug_struct("JsArrayBindingPatternRestElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrayBindingPatternRestElement> for SyntaxNode {
    fn from(n: JsArrayBindingPatternRestElement) -> Self {
        n.syntax
    }
}
impl From<JsArrayBindingPatternRestElement> for SyntaxElement {
    fn from(n: JsArrayBindingPatternRestElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrayExpression")
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("elements", &self.elements())
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsArrayExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrayExpression> for SyntaxNode {
    fn from(n: JsArrayExpression) -> Self {
        n.syntax
    }
}
impl From<JsArrayExpression> for SyntaxElement {
    fn from(n: JsArrayExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrayHole {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_HOLE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_HOLE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrayHole {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsArrayHole").finish()
    }
}
impl From<JsArrayHole> for SyntaxNode {
    fn from(n: JsArrayHole) -> Self {
        n.syntax
    }
}
impl From<JsArrayHole> for SyntaxElement {
    fn from(n: JsArrayHole) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsArrowFunctionExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARROW_FUNCTION_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARROW_FUNCTION_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsArrowFunctionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsArrowFunctionExpression")
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field(
                    "fat_arrow_token",
                    &support::DebugSyntaxResult(self.fat_arrow_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsArrowFunctionExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsArrowFunctionExpression> for SyntaxNode {
    fn from(n: JsArrowFunctionExpression) -> Self {
        n.syntax
    }
}
impl From<JsArrowFunctionExpression> for SyntaxElement {
    fn from(n: JsArrowFunctionExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsAssignmentExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ASSIGNMENT_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ASSIGNMENT_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsAssignmentExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsAssignmentExpression")
                .field("left", &support::DebugSyntaxResult(self.left()))
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("JsAssignmentExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsAssignmentExpression> for SyntaxNode {
    fn from(n: JsAssignmentExpression) -> Self {
        n.syntax
    }
}
impl From<JsAssignmentExpression> for SyntaxElement {
    fn from(n: JsAssignmentExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsAwaitExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_AWAIT_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_AWAIT_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsAwaitExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsAwaitExpression")
                .field(
                    "await_token",
                    &support::DebugSyntaxResult(self.await_token()),
                )
                .field("argument", &support::DebugSyntaxResult(self.argument()))
                .finish()
        } else {
            f.debug_struct("JsAwaitExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsAwaitExpression> for SyntaxNode {
    fn from(n: JsAwaitExpression) -> Self {
        n.syntax
    }
}
impl From<JsAwaitExpression> for SyntaxElement {
    fn from(n: JsAwaitExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsBigintLiteralExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BIGINT_LITERAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BIGINT_LITERAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBigintLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsBigintLiteralExpression")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsBigintLiteralExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsBigintLiteralExpression> for SyntaxNode {
    fn from(n: JsBigintLiteralExpression) -> Self {
        n.syntax
    }
}
impl From<JsBigintLiteralExpression> for SyntaxElement {
    fn from(n: JsBigintLiteralExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsBinaryExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BINARY_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BINARY_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBinaryExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsBinaryExpression")
                .field("left", &support::DebugSyntaxResult(self.left()))
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("JsBinaryExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsBinaryExpression> for SyntaxNode {
    fn from(n: JsBinaryExpression) -> Self {
        n.syntax
    }
}
impl From<JsBinaryExpression> for SyntaxElement {
    fn from(n: JsBinaryExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsBlockStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BLOCK_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BLOCK_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBlockStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsBlockStatement")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("statements", &self.statements())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsBlockStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsBlockStatement> for SyntaxNode {
    fn from(n: JsBlockStatement) -> Self {
        n.syntax
    }
}
impl From<JsBlockStatement> for SyntaxElement {
    fn from(n: JsBlockStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsBooleanLiteralExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOOLEAN_LITERAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOOLEAN_LITERAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBooleanLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsBooleanLiteralExpression")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsBooleanLiteralExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsBooleanLiteralExpression> for SyntaxNode {
    fn from(n: JsBooleanLiteralExpression) -> Self {
        n.syntax
    }
}
impl From<JsBooleanLiteralExpression> for SyntaxElement {
    fn from(n: JsBooleanLiteralExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsBreakStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BREAK_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BREAK_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBreakStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsBreakStatement")
                .field(
                    "break_token",
                    &support::DebugSyntaxResult(self.break_token()),
                )
                .field("label", &support::DebugOptionalElement(self.label()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsBreakStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsBreakStatement> for SyntaxNode {
    fn from(n: JsBreakStatement) -> Self {
        n.syntax
    }
}
impl From<JsBreakStatement> for SyntaxElement {
    fn from(n: JsBreakStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsCallArguments {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CALL_ARGUMENTS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CALL_ARGUMENTS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsCallArguments {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsCallArguments")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("args", &self.args())
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsCallArguments").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsCallArguments> for SyntaxNode {
    fn from(n: JsCallArguments) -> Self {
        n.syntax
    }
}
impl From<JsCallArguments> for SyntaxElement {
    fn from(n: JsCallArguments) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsCallExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CALL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CALL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsCallExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsCallExpression")
                .field("callee", &support::DebugSyntaxResult(self.callee()))
                .field(
                    "optional_chain_token",
                    &support::DebugOptionalElement(self.optional_chain_token()),
                )
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .field("arguments", &support::DebugSyntaxResult(self.arguments()))
                .finish()
        } else {
            f.debug_struct("JsCallExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsCallExpression> for SyntaxNode {
    fn from(n: JsCallExpression) -> Self {
        n.syntax
    }
}
impl From<JsCallExpression> for SyntaxElement {
    fn from(n: JsCallExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsCaseClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CASE_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CASE_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsCaseClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsCaseClause")
                .field("case_token", &support::DebugSyntaxResult(self.case_token()))
                .field("test", &support::DebugSyntaxResult(self.test()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("consequent", &self.consequent())
                .finish()
        } else {
            f.debug_struct("JsCaseClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsCaseClause> for SyntaxNode {
    fn from(n: JsCaseClause) -> Self {
        n.syntax
    }
}
impl From<JsCaseClause> for SyntaxElement {
    fn from(n: JsCaseClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsCatchClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CATCH_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CATCH_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsCatchClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsCatchClause")
                .field(
                    "catch_token",
                    &support::DebugSyntaxResult(self.catch_token()),
                )
                .field(
                    "declaration",
                    &support::DebugOptionalElement(self.declaration()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsCatchClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsCatchClause> for SyntaxNode {
    fn from(n: JsCatchClause) -> Self {
        n.syntax
    }
}
impl From<JsCatchClause> for SyntaxElement {
    fn from(n: JsCatchClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsCatchDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CATCH_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CATCH_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsCatchDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsCatchDeclaration")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("binding", &support::DebugSyntaxResult(self.binding()))
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsCatchDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsCatchDeclaration> for SyntaxNode {
    fn from(n: JsCatchDeclaration) -> Self {
        n.syntax
    }
}
impl From<JsCatchDeclaration> for SyntaxElement {
    fn from(n: JsCatchDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsClassDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CLASS_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CLASS_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsClassDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsClassDeclaration")
                .field("decorators", &self.decorators())
                .field(
                    "abstract_token",
                    &support::DebugOptionalElement(self.abstract_token()),
                )
                .field(
                    "class_token",
                    &support::DebugSyntaxResult(self.class_token()),
                )
                .field("id", &support::DebugSyntaxResult(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field(
                    "extends_clause",
                    &support::DebugOptionalElement(self.extends_clause()),
                )
                .field(
                    "implements_clause",
                    &support::DebugOptionalElement(self.implements_clause()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("members", &self.members())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsClassDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsClassDeclaration> for SyntaxNode {
    fn from(n: JsClassDeclaration) -> Self {
        n.syntax
    }
}
impl From<JsClassDeclaration> for SyntaxElement {
    fn from(n: JsClassDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsClassExportDefaultDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CLASS_EXPORT_DEFAULT_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CLASS_EXPORT_DEFAULT_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsClassExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsClassExportDefaultDeclaration")
                .field("decorators", &self.decorators())
                .field(
                    "abstract_token",
                    &support::DebugOptionalElement(self.abstract_token()),
                )
                .field(
                    "class_token",
                    &support::DebugSyntaxResult(self.class_token()),
                )
                .field("id", &support::DebugOptionalElement(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field(
                    "extends_clause",
                    &support::DebugOptionalElement(self.extends_clause()),
                )
                .field(
                    "implements_clause",
                    &support::DebugOptionalElement(self.implements_clause()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("members", &self.members())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsClassExportDefaultDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsClassExportDefaultDeclaration> for SyntaxNode {
    fn from(n: JsClassExportDefaultDeclaration) -> Self {
        n.syntax
    }
}
impl From<JsClassExportDefaultDeclaration> for SyntaxElement {
    fn from(n: JsClassExportDefaultDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsClassExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CLASS_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CLASS_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsClassExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsClassExpression")
                .field("decorators", &self.decorators())
                .field(
                    "class_token",
                    &support::DebugSyntaxResult(self.class_token()),
                )
                .field("id", &support::DebugOptionalElement(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field(
                    "extends_clause",
                    &support::DebugOptionalElement(self.extends_clause()),
                )
                .field(
                    "implements_clause",
                    &support::DebugOptionalElement(self.implements_clause()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("members", &self.members())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsClassExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsClassExpression> for SyntaxNode {
    fn from(n: JsClassExpression) -> Self {
        n.syntax
    }
}
impl From<JsClassExpression> for SyntaxElement {
    fn from(n: JsClassExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsComputedMemberAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_COMPUTED_MEMBER_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_COMPUTED_MEMBER_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsComputedMemberAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsComputedMemberAssignment")
                .field("object", &support::DebugSyntaxResult(self.object()))
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("member", &support::DebugSyntaxResult(self.member()))
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsComputedMemberAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsComputedMemberAssignment> for SyntaxNode {
    fn from(n: JsComputedMemberAssignment) -> Self {
        n.syntax
    }
}
impl From<JsComputedMemberAssignment> for SyntaxElement {
    fn from(n: JsComputedMemberAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsComputedMemberExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_COMPUTED_MEMBER_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_COMPUTED_MEMBER_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsComputedMemberExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsComputedMemberExpression")
                .field("object", &support::DebugSyntaxResult(self.object()))
                .field(
                    "optional_chain_token",
                    &support::DebugOptionalElement(self.optional_chain_token()),
                )
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("member", &support::DebugSyntaxResult(self.member()))
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsComputedMemberExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsComputedMemberExpression> for SyntaxNode {
    fn from(n: JsComputedMemberExpression) -> Self {
        n.syntax
    }
}
impl From<JsComputedMemberExpression> for SyntaxElement {
    fn from(n: JsComputedMemberExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsComputedMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_COMPUTED_MEMBER_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_COMPUTED_MEMBER_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsComputedMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsComputedMemberName")
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsComputedMemberName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsComputedMemberName> for SyntaxNode {
    fn from(n: JsComputedMemberName) -> Self {
        n.syntax
    }
}
impl From<JsComputedMemberName> for SyntaxElement {
    fn from(n: JsComputedMemberName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsConditionalExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CONDITIONAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CONDITIONAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsConditionalExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsConditionalExpression")
                .field("test", &support::DebugSyntaxResult(self.test()))
                .field(
                    "question_mark_token",
                    &support::DebugSyntaxResult(self.question_mark_token()),
                )
                .field("consequent", &support::DebugSyntaxResult(self.consequent()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("alternate", &support::DebugSyntaxResult(self.alternate()))
                .finish()
        } else {
            f.debug_struct("JsConditionalExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsConditionalExpression> for SyntaxNode {
    fn from(n: JsConditionalExpression) -> Self {
        n.syntax
    }
}
impl From<JsConditionalExpression> for SyntaxElement {
    fn from(n: JsConditionalExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsConstructorClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CONSTRUCTOR_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CONSTRUCTOR_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsConstructorClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsConstructorClassMember")
                .field("modifiers", &self.modifiers())
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsConstructorClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsConstructorClassMember> for SyntaxNode {
    fn from(n: JsConstructorClassMember) -> Self {
        n.syntax
    }
}
impl From<JsConstructorClassMember> for SyntaxElement {
    fn from(n: JsConstructorClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsConstructorParameters {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CONSTRUCTOR_PARAMETERS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CONSTRUCTOR_PARAMETERS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsConstructorParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsConstructorParameters")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("parameters", &self.parameters())
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsConstructorParameters").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsConstructorParameters> for SyntaxNode {
    fn from(n: JsConstructorParameters) -> Self {
        n.syntax
    }
}
impl From<JsConstructorParameters> for SyntaxElement {
    fn from(n: JsConstructorParameters) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsContinueStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CONTINUE_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CONTINUE_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsContinueStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsContinueStatement")
                .field(
                    "continue_token",
                    &support::DebugSyntaxResult(self.continue_token()),
                )
                .field("label", &support::DebugOptionalElement(self.label()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsContinueStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsContinueStatement> for SyntaxNode {
    fn from(n: JsContinueStatement) -> Self {
        n.syntax
    }
}
impl From<JsContinueStatement> for SyntaxElement {
    fn from(n: JsContinueStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsDebuggerStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DEBUGGER_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DEBUGGER_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsDebuggerStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsDebuggerStatement")
                .field(
                    "debugger_token",
                    &support::DebugSyntaxResult(self.debugger_token()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsDebuggerStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsDebuggerStatement> for SyntaxNode {
    fn from(n: JsDebuggerStatement) -> Self {
        n.syntax
    }
}
impl From<JsDebuggerStatement> for SyntaxElement {
    fn from(n: JsDebuggerStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsDecorator {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DECORATOR as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DECORATOR
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsDecorator {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsDecorator")
                .field("at_token", &support::DebugSyntaxResult(self.at_token()))
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .finish()
        } else {
            f.debug_struct("JsDecorator").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsDecorator> for SyntaxNode {
    fn from(n: JsDecorator) -> Self {
        n.syntax
    }
}
impl From<JsDecorator> for SyntaxElement {
    fn from(n: JsDecorator) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsDefaultClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DEFAULT_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DEFAULT_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsDefaultClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsDefaultClause")
                .field(
                    "default_token",
                    &support::DebugSyntaxResult(self.default_token()),
                )
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("consequent", &self.consequent())
                .finish()
        } else {
            f.debug_struct("JsDefaultClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsDefaultClause> for SyntaxNode {
    fn from(n: JsDefaultClause) -> Self {
        n.syntax
    }
}
impl From<JsDefaultClause> for SyntaxElement {
    fn from(n: JsDefaultClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsDefaultImportSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DEFAULT_IMPORT_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DEFAULT_IMPORT_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsDefaultImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsDefaultImportSpecifier")
                .field("local_name", &support::DebugSyntaxResult(self.local_name()))
                .finish()
        } else {
            f.debug_struct("JsDefaultImportSpecifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsDefaultImportSpecifier> for SyntaxNode {
    fn from(n: JsDefaultImportSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsDefaultImportSpecifier> for SyntaxElement {
    fn from(n: JsDefaultImportSpecifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsDirective {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DIRECTIVE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DIRECTIVE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsDirective {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsDirective")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsDirective").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsDirective> for SyntaxNode {
    fn from(n: JsDirective) -> Self {
        n.syntax
    }
}
impl From<JsDirective> for SyntaxElement {
    fn from(n: JsDirective) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsDoWhileStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DO_WHILE_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DO_WHILE_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsDoWhileStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsDoWhileStatement")
                .field("do_token", &support::DebugSyntaxResult(self.do_token()))
                .field("body", &support::DebugSyntaxResult(self.body()))
                .field(
                    "while_token",
                    &support::DebugSyntaxResult(self.while_token()),
                )
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("test", &support::DebugSyntaxResult(self.test()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsDoWhileStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsDoWhileStatement> for SyntaxNode {
    fn from(n: JsDoWhileStatement) -> Self {
        n.syntax
    }
}
impl From<JsDoWhileStatement> for SyntaxElement {
    fn from(n: JsDoWhileStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsElseClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ELSE_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ELSE_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsElseClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsElseClause")
                .field("else_token", &support::DebugSyntaxResult(self.else_token()))
                .field("alternate", &support::DebugSyntaxResult(self.alternate()))
                .finish()
        } else {
            f.debug_struct("JsElseClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsElseClause> for SyntaxNode {
    fn from(n: JsElseClause) -> Self {
        n.syntax
    }
}
impl From<JsElseClause> for SyntaxElement {
    fn from(n: JsElseClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsEmptyClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EMPTY_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EMPTY_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsEmptyClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsEmptyClassMember")
                .field(
                    "semicolon_token",
                    &support::DebugSyntaxResult(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsEmptyClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsEmptyClassMember> for SyntaxNode {
    fn from(n: JsEmptyClassMember) -> Self {
        n.syntax
    }
}
impl From<JsEmptyClassMember> for SyntaxElement {
    fn from(n: JsEmptyClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsEmptyStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EMPTY_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EMPTY_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsEmptyStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsEmptyStatement")
                .field(
                    "semicolon_token",
                    &support::DebugSyntaxResult(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsEmptyStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsEmptyStatement> for SyntaxNode {
    fn from(n: JsEmptyStatement) -> Self {
        n.syntax
    }
}
impl From<JsEmptyStatement> for SyntaxElement {
    fn from(n: JsEmptyStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExport {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExport {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExport")
                .field("decorators", &self.decorators())
                .field(
                    "export_token",
                    &support::DebugSyntaxResult(self.export_token()),
                )
                .field(
                    "export_clause",
                    &support::DebugSyntaxResult(self.export_clause()),
                )
                .finish()
        } else {
            f.debug_struct("JsExport").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExport> for SyntaxNode {
    fn from(n: JsExport) -> Self {
        n.syntax
    }
}
impl From<JsExport> for SyntaxElement {
    fn from(n: JsExport) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportAsClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_AS_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_AS_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportAsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportAsClause")
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field(
                    "exported_name",
                    &support::DebugSyntaxResult(self.exported_name()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportAsClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportAsClause> for SyntaxNode {
    fn from(n: JsExportAsClause) -> Self {
        n.syntax
    }
}
impl From<JsExportAsClause> for SyntaxElement {
    fn from(n: JsExportAsClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportDefaultDeclarationClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_DEFAULT_DECLARATION_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_DEFAULT_DECLARATION_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportDefaultDeclarationClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportDefaultDeclarationClause")
                .field(
                    "default_token",
                    &support::DebugSyntaxResult(self.default_token()),
                )
                .field(
                    "declaration",
                    &support::DebugSyntaxResult(self.declaration()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportDefaultDeclarationClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportDefaultDeclarationClause> for SyntaxNode {
    fn from(n: JsExportDefaultDeclarationClause) -> Self {
        n.syntax
    }
}
impl From<JsExportDefaultDeclarationClause> for SyntaxElement {
    fn from(n: JsExportDefaultDeclarationClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportDefaultExpressionClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_DEFAULT_EXPRESSION_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_DEFAULT_EXPRESSION_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportDefaultExpressionClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportDefaultExpressionClause")
                .field(
                    "default_token",
                    &support::DebugSyntaxResult(self.default_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportDefaultExpressionClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportDefaultExpressionClause> for SyntaxNode {
    fn from(n: JsExportDefaultExpressionClause) -> Self {
        n.syntax
    }
}
impl From<JsExportDefaultExpressionClause> for SyntaxElement {
    fn from(n: JsExportDefaultExpressionClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportFromClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_FROM_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_FROM_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportFromClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportFromClause")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field("star_token", &support::DebugSyntaxResult(self.star_token()))
                .field(
                    "export_as",
                    &support::DebugOptionalElement(self.export_as()),
                )
                .field("from_token", &support::DebugSyntaxResult(self.from_token()))
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "assertion",
                    &support::DebugOptionalElement(self.assertion()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportFromClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportFromClause> for SyntaxNode {
    fn from(n: JsExportFromClause) -> Self {
        n.syntax
    }
}
impl From<JsExportFromClause> for SyntaxElement {
    fn from(n: JsExportFromClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportNamedClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_NAMED_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_NAMED_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportNamedClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportNamedClause")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("specifiers", &self.specifiers())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportNamedClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportNamedClause> for SyntaxNode {
    fn from(n: JsExportNamedClause) -> Self {
        n.syntax
    }
}
impl From<JsExportNamedClause> for SyntaxElement {
    fn from(n: JsExportNamedClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportNamedFromClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_NAMED_FROM_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_NAMED_FROM_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportNamedFromClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportNamedFromClause")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("specifiers", &self.specifiers())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .field("from_token", &support::DebugSyntaxResult(self.from_token()))
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "assertion",
                    &support::DebugOptionalElement(self.assertion()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportNamedFromClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportNamedFromClause> for SyntaxNode {
    fn from(n: JsExportNamedFromClause) -> Self {
        n.syntax
    }
}
impl From<JsExportNamedFromClause> for SyntaxElement {
    fn from(n: JsExportNamedFromClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportNamedFromSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_NAMED_FROM_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_NAMED_FROM_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportNamedFromSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportNamedFromSpecifier")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field(
                    "source_name",
                    &support::DebugSyntaxResult(self.source_name()),
                )
                .field(
                    "export_as",
                    &support::DebugOptionalElement(self.export_as()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportNamedFromSpecifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportNamedFromSpecifier> for SyntaxNode {
    fn from(n: JsExportNamedFromSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsExportNamedFromSpecifier> for SyntaxElement {
    fn from(n: JsExportNamedFromSpecifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportNamedShorthandSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_NAMED_SHORTHAND_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_NAMED_SHORTHAND_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportNamedShorthandSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportNamedShorthandSpecifier")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .finish()
        } else {
            f.debug_struct("JsExportNamedShorthandSpecifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportNamedShorthandSpecifier> for SyntaxNode {
    fn from(n: JsExportNamedShorthandSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsExportNamedShorthandSpecifier> for SyntaxElement {
    fn from(n: JsExportNamedShorthandSpecifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExportNamedSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_NAMED_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_NAMED_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExportNamedSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExportNamedSpecifier")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field("local_name", &support::DebugSyntaxResult(self.local_name()))
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field(
                    "exported_name",
                    &support::DebugSyntaxResult(self.exported_name()),
                )
                .finish()
        } else {
            f.debug_struct("JsExportNamedSpecifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExportNamedSpecifier> for SyntaxNode {
    fn from(n: JsExportNamedSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsExportNamedSpecifier> for SyntaxElement {
    fn from(n: JsExportNamedSpecifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExpressionSnipped {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPRESSION_SNIPPED as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPRESSION_SNIPPED
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExpressionSnipped {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExpressionSnipped")
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field("eof_token", &support::DebugSyntaxResult(self.eof_token()))
                .finish()
        } else {
            f.debug_struct("JsExpressionSnipped").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExpressionSnipped> for SyntaxNode {
    fn from(n: JsExpressionSnipped) -> Self {
        n.syntax
    }
}
impl From<JsExpressionSnipped> for SyntaxElement {
    fn from(n: JsExpressionSnipped) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExpressionStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPRESSION_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPRESSION_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExpressionStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExpressionStatement")
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsExpressionStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExpressionStatement> for SyntaxNode {
    fn from(n: JsExpressionStatement) -> Self {
        n.syntax
    }
}
impl From<JsExpressionStatement> for SyntaxElement {
    fn from(n: JsExpressionStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsExtendsClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXTENDS_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXTENDS_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsExtendsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsExtendsClause")
                .field(
                    "extends_token",
                    &support::DebugSyntaxResult(self.extends_token()),
                )
                .field(
                    "super_class",
                    &support::DebugSyntaxResult(self.super_class()),
                )
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .finish()
        } else {
            f.debug_struct("JsExtendsClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsExtendsClause> for SyntaxNode {
    fn from(n: JsExtendsClause) -> Self {
        n.syntax
    }
}
impl From<JsExtendsClause> for SyntaxElement {
    fn from(n: JsExtendsClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsFinallyClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FINALLY_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FINALLY_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsFinallyClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsFinallyClause")
                .field(
                    "finally_token",
                    &support::DebugSyntaxResult(self.finally_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsFinallyClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsFinallyClause> for SyntaxNode {
    fn from(n: JsFinallyClause) -> Self {
        n.syntax
    }
}
impl From<JsFinallyClause> for SyntaxElement {
    fn from(n: JsFinallyClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsForInStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FOR_IN_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FOR_IN_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsForInStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsForInStatement")
                .field("for_token", &support::DebugSyntaxResult(self.for_token()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "initializer",
                    &support::DebugSyntaxResult(self.initializer()),
                )
                .field("in_token", &support::DebugSyntaxResult(self.in_token()))
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsForInStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsForInStatement> for SyntaxNode {
    fn from(n: JsForInStatement) -> Self {
        n.syntax
    }
}
impl From<JsForInStatement> for SyntaxElement {
    fn from(n: JsForInStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsForOfStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FOR_OF_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FOR_OF_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsForOfStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsForOfStatement")
                .field("for_token", &support::DebugSyntaxResult(self.for_token()))
                .field(
                    "await_token",
                    &support::DebugOptionalElement(self.await_token()),
                )
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "initializer",
                    &support::DebugSyntaxResult(self.initializer()),
                )
                .field("of_token", &support::DebugSyntaxResult(self.of_token()))
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsForOfStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsForOfStatement> for SyntaxNode {
    fn from(n: JsForOfStatement) -> Self {
        n.syntax
    }
}
impl From<JsForOfStatement> for SyntaxElement {
    fn from(n: JsForOfStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsForStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FOR_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FOR_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsForStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsForStatement")
                .field("for_token", &support::DebugSyntaxResult(self.for_token()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "initializer",
                    &support::DebugOptionalElement(self.initializer()),
                )
                .field(
                    "first_semi_token",
                    &support::DebugSyntaxResult(self.first_semi_token()),
                )
                .field("test", &support::DebugOptionalElement(self.test()))
                .field(
                    "second_semi_token",
                    &support::DebugSyntaxResult(self.second_semi_token()),
                )
                .field("update", &support::DebugOptionalElement(self.update()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsForStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsForStatement> for SyntaxNode {
    fn from(n: JsForStatement) -> Self {
        n.syntax
    }
}
impl From<JsForStatement> for SyntaxElement {
    fn from(n: JsForStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsForVariableDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FOR_VARIABLE_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FOR_VARIABLE_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsForVariableDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsForVariableDeclaration")
                .field(
                    "await_token",
                    &support::DebugOptionalElement(self.await_token()),
                )
                .field("kind_token", &support::DebugSyntaxResult(self.kind_token()))
                .field("declarator", &support::DebugSyntaxResult(self.declarator()))
                .finish()
        } else {
            f.debug_struct("JsForVariableDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsForVariableDeclaration> for SyntaxNode {
    fn from(n: JsForVariableDeclaration) -> Self {
        n.syntax
    }
}
impl From<JsForVariableDeclaration> for SyntaxElement {
    fn from(n: JsForVariableDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsFormalParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FORMAL_PARAMETER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FORMAL_PARAMETER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsFormalParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsFormalParameter")
                .field("decorators", &self.decorators())
                .field("binding", &support::DebugSyntaxResult(self.binding()))
                .field(
                    "question_mark_token",
                    &support::DebugOptionalElement(self.question_mark_token()),
                )
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .field(
                    "initializer",
                    &support::DebugOptionalElement(self.initializer()),
                )
                .finish()
        } else {
            f.debug_struct("JsFormalParameter").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsFormalParameter> for SyntaxNode {
    fn from(n: JsFormalParameter) -> Self {
        n.syntax
    }
}
impl From<JsFormalParameter> for SyntaxElement {
    fn from(n: JsFormalParameter) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsFunctionBody {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FUNCTION_BODY as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FUNCTION_BODY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsFunctionBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsFunctionBody")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("directives", &self.directives())
                .field("statements", &self.statements())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsFunctionBody").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsFunctionBody> for SyntaxNode {
    fn from(n: JsFunctionBody) -> Self {
        n.syntax
    }
}
impl From<JsFunctionBody> for SyntaxElement {
    fn from(n: JsFunctionBody) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsFunctionDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FUNCTION_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FUNCTION_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsFunctionDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsFunctionDeclaration")
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "function_token",
                    &support::DebugSyntaxResult(self.function_token()),
                )
                .field(
                    "star_token",
                    &support::DebugOptionalElement(self.star_token()),
                )
                .field("id", &support::DebugSyntaxResult(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsFunctionDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsFunctionDeclaration> for SyntaxNode {
    fn from(n: JsFunctionDeclaration) -> Self {
        n.syntax
    }
}
impl From<JsFunctionDeclaration> for SyntaxElement {
    fn from(n: JsFunctionDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsFunctionExportDefaultDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FUNCTION_EXPORT_DEFAULT_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FUNCTION_EXPORT_DEFAULT_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsFunctionExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsFunctionExportDefaultDeclaration")
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "function_token",
                    &support::DebugSyntaxResult(self.function_token()),
                )
                .field(
                    "star_token",
                    &support::DebugOptionalElement(self.star_token()),
                )
                .field("id", &support::DebugOptionalElement(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsFunctionExportDefaultDeclaration")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsFunctionExportDefaultDeclaration> for SyntaxNode {
    fn from(n: JsFunctionExportDefaultDeclaration) -> Self {
        n.syntax
    }
}
impl From<JsFunctionExportDefaultDeclaration> for SyntaxElement {
    fn from(n: JsFunctionExportDefaultDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsFunctionExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_FUNCTION_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_FUNCTION_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsFunctionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsFunctionExpression")
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "function_token",
                    &support::DebugSyntaxResult(self.function_token()),
                )
                .field(
                    "star_token",
                    &support::DebugOptionalElement(self.star_token()),
                )
                .field("id", &support::DebugOptionalElement(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsFunctionExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsFunctionExpression> for SyntaxNode {
    fn from(n: JsFunctionExpression) -> Self {
        n.syntax
    }
}
impl From<JsFunctionExpression> for SyntaxElement {
    fn from(n: JsFunctionExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsGetterClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_GETTER_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_GETTER_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsGetterClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsGetterClassMember")
                .field("modifiers", &self.modifiers())
                .field("get_token", &support::DebugSyntaxResult(self.get_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "return_type",
                    &support::DebugOptionalElement(self.return_type()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsGetterClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsGetterClassMember> for SyntaxNode {
    fn from(n: JsGetterClassMember) -> Self {
        n.syntax
    }
}
impl From<JsGetterClassMember> for SyntaxElement {
    fn from(n: JsGetterClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsGetterObjectMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_GETTER_OBJECT_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_GETTER_OBJECT_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsGetterObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsGetterObjectMember")
                .field("get_token", &support::DebugSyntaxResult(self.get_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "return_type",
                    &support::DebugOptionalElement(self.return_type()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsGetterObjectMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsGetterObjectMember> for SyntaxNode {
    fn from(n: JsGetterObjectMember) -> Self {
        n.syntax
    }
}
impl From<JsGetterObjectMember> for SyntaxElement {
    fn from(n: JsGetterObjectMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsIdentifierAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IDENTIFIER_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IDENTIFIER_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsIdentifierAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsIdentifierAssignment")
                .field("name_token", &support::DebugSyntaxResult(self.name_token()))
                .finish()
        } else {
            f.debug_struct("JsIdentifierAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsIdentifierAssignment> for SyntaxNode {
    fn from(n: JsIdentifierAssignment) -> Self {
        n.syntax
    }
}
impl From<JsIdentifierAssignment> for SyntaxElement {
    fn from(n: JsIdentifierAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsIdentifierBinding {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IDENTIFIER_BINDING as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IDENTIFIER_BINDING
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsIdentifierBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsIdentifierBinding")
                .field("name_token", &support::DebugSyntaxResult(self.name_token()))
                .finish()
        } else {
            f.debug_struct("JsIdentifierBinding").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsIdentifierBinding> for SyntaxNode {
    fn from(n: JsIdentifierBinding) -> Self {
        n.syntax
    }
}
impl From<JsIdentifierBinding> for SyntaxElement {
    fn from(n: JsIdentifierBinding) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsIdentifierExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IDENTIFIER_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IDENTIFIER_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsIdentifierExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsIdentifierExpression")
                .field("name", &support::DebugSyntaxResult(self.name()))
                .finish()
        } else {
            f.debug_struct("JsIdentifierExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsIdentifierExpression> for SyntaxNode {
    fn from(n: JsIdentifierExpression) -> Self {
        n.syntax
    }
}
impl From<JsIdentifierExpression> for SyntaxElement {
    fn from(n: JsIdentifierExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsIfStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IF_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IF_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsIfStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsIfStatement")
                .field("if_token", &support::DebugSyntaxResult(self.if_token()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("test", &support::DebugSyntaxResult(self.test()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("consequent", &support::DebugSyntaxResult(self.consequent()))
                .field(
                    "else_clause",
                    &support::DebugOptionalElement(self.else_clause()),
                )
                .finish()
        } else {
            f.debug_struct("JsIfStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsIfStatement> for SyntaxNode {
    fn from(n: JsIfStatement) -> Self {
        n.syntax
    }
}
impl From<JsIfStatement> for SyntaxElement {
    fn from(n: JsIfStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImport {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImport {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImport")
                .field(
                    "import_token",
                    &support::DebugSyntaxResult(self.import_token()),
                )
                .field(
                    "import_clause",
                    &support::DebugSyntaxResult(self.import_clause()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsImport").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImport> for SyntaxNode {
    fn from(n: JsImport) -> Self {
        n.syntax
    }
}
impl From<JsImport> for SyntaxElement {
    fn from(n: JsImport) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportAssertion {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_ASSERTION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_ASSERTION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportAssertion {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportAssertion")
                .field("with_token", &support::DebugSyntaxResult(self.with_token()))
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("assertions", &self.assertions())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsImportAssertion").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportAssertion> for SyntaxNode {
    fn from(n: JsImportAssertion) -> Self {
        n.syntax
    }
}
impl From<JsImportAssertion> for SyntaxElement {
    fn from(n: JsImportAssertion) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportAssertionEntry {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_ASSERTION_ENTRY as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_ASSERTION_ENTRY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportAssertionEntry {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportAssertionEntry")
                .field("key", &support::DebugSyntaxResult(self.key()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsImportAssertionEntry").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportAssertionEntry> for SyntaxNode {
    fn from(n: JsImportAssertionEntry) -> Self {
        n.syntax
    }
}
impl From<JsImportAssertionEntry> for SyntaxElement {
    fn from(n: JsImportAssertionEntry) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportBareClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_BARE_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_BARE_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportBareClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportBareClause")
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "assertion",
                    &support::DebugOptionalElement(self.assertion()),
                )
                .finish()
        } else {
            f.debug_struct("JsImportBareClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportBareClause> for SyntaxNode {
    fn from(n: JsImportBareClause) -> Self {
        n.syntax
    }
}
impl From<JsImportBareClause> for SyntaxElement {
    fn from(n: JsImportBareClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportCallExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_CALL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_CALL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportCallExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportCallExpression")
                .field(
                    "import_token",
                    &support::DebugSyntaxResult(self.import_token()),
                )
                .field(
                    "dot_token",
                    &support::DebugOptionalElement(self.dot_token()),
                )
                .field("phase", &support::DebugOptionalElement(self.phase()))
                .field("arguments", &support::DebugSyntaxResult(self.arguments()))
                .finish()
        } else {
            f.debug_struct("JsImportCallExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportCallExpression> for SyntaxNode {
    fn from(n: JsImportCallExpression) -> Self {
        n.syntax
    }
}
impl From<JsImportCallExpression> for SyntaxElement {
    fn from(n: JsImportCallExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportCombinedClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_COMBINED_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_COMBINED_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportCombinedClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportCombinedClause")
                .field(
                    "default_specifier",
                    &support::DebugSyntaxResult(self.default_specifier()),
                )
                .field(
                    "comma_token",
                    &support::DebugSyntaxResult(self.comma_token()),
                )
                .field("specifier", &support::DebugSyntaxResult(self.specifier()))
                .field("from_token", &support::DebugSyntaxResult(self.from_token()))
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "assertion",
                    &support::DebugOptionalElement(self.assertion()),
                )
                .finish()
        } else {
            f.debug_struct("JsImportCombinedClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportCombinedClause> for SyntaxNode {
    fn from(n: JsImportCombinedClause) -> Self {
        n.syntax
    }
}
impl From<JsImportCombinedClause> for SyntaxElement {
    fn from(n: JsImportCombinedClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportDefaultClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_DEFAULT_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_DEFAULT_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportDefaultClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportDefaultClause")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field(
                    "phase_token",
                    &support::DebugOptionalElement(self.phase_token()),
                )
                .field(
                    "default_specifier",
                    &support::DebugSyntaxResult(self.default_specifier()),
                )
                .field("from_token", &support::DebugSyntaxResult(self.from_token()))
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "assertion",
                    &support::DebugOptionalElement(self.assertion()),
                )
                .finish()
        } else {
            f.debug_struct("JsImportDefaultClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportDefaultClause> for SyntaxNode {
    fn from(n: JsImportDefaultClause) -> Self {
        n.syntax
    }
}
impl From<JsImportDefaultClause> for SyntaxElement {
    fn from(n: JsImportDefaultClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportMetaExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_META_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_META_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportMetaExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportMetaExpression")
                .field(
                    "import_token",
                    &support::DebugSyntaxResult(self.import_token()),
                )
                .field("dot_token", &support::DebugSyntaxResult(self.dot_token()))
                .field("meta_token", &support::DebugSyntaxResult(self.meta_token()))
                .finish()
        } else {
            f.debug_struct("JsImportMetaExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportMetaExpression> for SyntaxNode {
    fn from(n: JsImportMetaExpression) -> Self {
        n.syntax
    }
}
impl From<JsImportMetaExpression> for SyntaxElement {
    fn from(n: JsImportMetaExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportNamedClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_NAMED_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_NAMED_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportNamedClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportNamedClause")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field(
                    "named_specifiers",
                    &support::DebugSyntaxResult(self.named_specifiers()),
                )
                .field("from_token", &support::DebugSyntaxResult(self.from_token()))
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "assertion",
                    &support::DebugOptionalElement(self.assertion()),
                )
                .finish()
        } else {
            f.debug_struct("JsImportNamedClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportNamedClause> for SyntaxNode {
    fn from(n: JsImportNamedClause) -> Self {
        n.syntax
    }
}
impl From<JsImportNamedClause> for SyntaxElement {
    fn from(n: JsImportNamedClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsImportNamespaceClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_NAMESPACE_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_NAMESPACE_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsImportNamespaceClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsImportNamespaceClause")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field(
                    "phase_token",
                    &support::DebugOptionalElement(self.phase_token()),
                )
                .field(
                    "namespace_specifier",
                    &support::DebugSyntaxResult(self.namespace_specifier()),
                )
                .field("from_token", &support::DebugSyntaxResult(self.from_token()))
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "assertion",
                    &support::DebugOptionalElement(self.assertion()),
                )
                .finish()
        } else {
            f.debug_struct("JsImportNamespaceClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsImportNamespaceClause> for SyntaxNode {
    fn from(n: JsImportNamespaceClause) -> Self {
        n.syntax
    }
}
impl From<JsImportNamespaceClause> for SyntaxElement {
    fn from(n: JsImportNamespaceClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsInExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IN_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IN_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsInExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsInExpression")
                .field("property", &support::DebugSyntaxResult(self.property()))
                .field("in_token", &support::DebugSyntaxResult(self.in_token()))
                .field("object", &support::DebugSyntaxResult(self.object()))
                .finish()
        } else {
            f.debug_struct("JsInExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsInExpression> for SyntaxNode {
    fn from(n: JsInExpression) -> Self {
        n.syntax
    }
}
impl From<JsInExpression> for SyntaxElement {
    fn from(n: JsInExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsInitializerClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_INITIALIZER_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_INITIALIZER_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsInitializerClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsInitializerClause")
                .field("eq_token", &support::DebugSyntaxResult(self.eq_token()))
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .finish()
        } else {
            f.debug_struct("JsInitializerClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsInitializerClause> for SyntaxNode {
    fn from(n: JsInitializerClause) -> Self {
        n.syntax
    }
}
impl From<JsInitializerClause> for SyntaxElement {
    fn from(n: JsInitializerClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsInstanceofExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_INSTANCEOF_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_INSTANCEOF_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsInstanceofExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsInstanceofExpression")
                .field("left", &support::DebugSyntaxResult(self.left()))
                .field(
                    "instanceof_token",
                    &support::DebugSyntaxResult(self.instanceof_token()),
                )
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("JsInstanceofExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsInstanceofExpression> for SyntaxNode {
    fn from(n: JsInstanceofExpression) -> Self {
        n.syntax
    }
}
impl From<JsInstanceofExpression> for SyntaxElement {
    fn from(n: JsInstanceofExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsLabel {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_LABEL as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_LABEL
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsLabel {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsLabel")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsLabel").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsLabel> for SyntaxNode {
    fn from(n: JsLabel) -> Self {
        n.syntax
    }
}
impl From<JsLabel> for SyntaxElement {
    fn from(n: JsLabel) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsLabeledStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_LABELED_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_LABELED_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsLabeledStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsLabeledStatement")
                .field("label", &support::DebugSyntaxResult(self.label()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsLabeledStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsLabeledStatement> for SyntaxNode {
    fn from(n: JsLabeledStatement) -> Self {
        n.syntax
    }
}
impl From<JsLabeledStatement> for SyntaxElement {
    fn from(n: JsLabeledStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsLiteralExportName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_LITERAL_EXPORT_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_LITERAL_EXPORT_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsLiteralExportName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsLiteralExportName")
                .field("value", &support::DebugSyntaxResult(self.value()))
                .finish()
        } else {
            f.debug_struct("JsLiteralExportName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsLiteralExportName> for SyntaxNode {
    fn from(n: JsLiteralExportName) -> Self {
        n.syntax
    }
}
impl From<JsLiteralExportName> for SyntaxElement {
    fn from(n: JsLiteralExportName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsLiteralMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_LITERAL_MEMBER_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_LITERAL_MEMBER_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsLiteralMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsLiteralMemberName")
                .field("value", &support::DebugSyntaxResult(self.value()))
                .finish()
        } else {
            f.debug_struct("JsLiteralMemberName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsLiteralMemberName> for SyntaxNode {
    fn from(n: JsLiteralMemberName) -> Self {
        n.syntax
    }
}
impl From<JsLiteralMemberName> for SyntaxElement {
    fn from(n: JsLiteralMemberName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsLogicalExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_LOGICAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_LOGICAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsLogicalExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsLogicalExpression")
                .field("left", &support::DebugSyntaxResult(self.left()))
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("JsLogicalExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsLogicalExpression> for SyntaxNode {
    fn from(n: JsLogicalExpression) -> Self {
        n.syntax
    }
}
impl From<JsLogicalExpression> for SyntaxElement {
    fn from(n: JsLogicalExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsMetavariable {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_METAVARIABLE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_METAVARIABLE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsMetavariable {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsMetavariable")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsMetavariable").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsMetavariable> for SyntaxNode {
    fn from(n: JsMetavariable) -> Self {
        n.syntax
    }
}
impl From<JsMetavariable> for SyntaxElement {
    fn from(n: JsMetavariable) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsMethodClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_METHOD_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_METHOD_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsMethodClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsMethodClassMember")
                .field("modifiers", &self.modifiers())
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "star_token",
                    &support::DebugOptionalElement(self.star_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "question_mark_token",
                    &support::DebugOptionalElement(self.question_mark_token()),
                )
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsMethodClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsMethodClassMember> for SyntaxNode {
    fn from(n: JsMethodClassMember) -> Self {
        n.syntax
    }
}
impl From<JsMethodClassMember> for SyntaxElement {
    fn from(n: JsMethodClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsMethodObjectMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_METHOD_OBJECT_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_METHOD_OBJECT_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsMethodObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsMethodObjectMember")
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "star_token",
                    &support::DebugOptionalElement(self.star_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsMethodObjectMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsMethodObjectMember> for SyntaxNode {
    fn from(n: JsMethodObjectMember) -> Self {
        n.syntax
    }
}
impl From<JsMethodObjectMember> for SyntaxElement {
    fn from(n: JsMethodObjectMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsModule {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_MODULE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_MODULE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsModule {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsModule")
                .field(
                    "bom_token",
                    &support::DebugOptionalElement(self.bom_token()),
                )
                .field(
                    "interpreter_token",
                    &support::DebugOptionalElement(self.interpreter_token()),
                )
                .field("directives", &self.directives())
                .field("items", &self.items())
                .field("eof_token", &support::DebugSyntaxResult(self.eof_token()))
                .finish()
        } else {
            f.debug_struct("JsModule").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsModule> for SyntaxNode {
    fn from(n: JsModule) -> Self {
        n.syntax
    }
}
impl From<JsModule> for SyntaxElement {
    fn from(n: JsModule) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsModuleSource {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_MODULE_SOURCE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_MODULE_SOURCE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsModuleSource {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsModuleSource")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsModuleSource").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsModuleSource> for SyntaxNode {
    fn from(n: JsModuleSource) -> Self {
        n.syntax
    }
}
impl From<JsModuleSource> for SyntaxElement {
    fn from(n: JsModuleSource) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsName")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsName> for SyntaxNode {
    fn from(n: JsName) -> Self {
        n.syntax
    }
}
impl From<JsName> for SyntaxElement {
    fn from(n: JsName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsNamedImportSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NAMED_IMPORT_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NAMED_IMPORT_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsNamedImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsNamedImportSpecifier")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field("local_name", &support::DebugSyntaxResult(self.local_name()))
                .finish()
        } else {
            f.debug_struct("JsNamedImportSpecifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsNamedImportSpecifier> for SyntaxNode {
    fn from(n: JsNamedImportSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsNamedImportSpecifier> for SyntaxElement {
    fn from(n: JsNamedImportSpecifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsNamedImportSpecifiers {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NAMED_IMPORT_SPECIFIERS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NAMED_IMPORT_SPECIFIERS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsNamedImportSpecifiers {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsNamedImportSpecifiers")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("specifiers", &self.specifiers())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsNamedImportSpecifiers").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsNamedImportSpecifiers> for SyntaxNode {
    fn from(n: JsNamedImportSpecifiers) -> Self {
        n.syntax
    }
}
impl From<JsNamedImportSpecifiers> for SyntaxElement {
    fn from(n: JsNamedImportSpecifiers) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsNamespaceImportSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NAMESPACE_IMPORT_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NAMESPACE_IMPORT_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsNamespaceImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsNamespaceImportSpecifier")
                .field("star_token", &support::DebugSyntaxResult(self.star_token()))
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field("local_name", &support::DebugSyntaxResult(self.local_name()))
                .finish()
        } else {
            f.debug_struct("JsNamespaceImportSpecifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsNamespaceImportSpecifier> for SyntaxNode {
    fn from(n: JsNamespaceImportSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsNamespaceImportSpecifier> for SyntaxElement {
    fn from(n: JsNamespaceImportSpecifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsNewExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NEW_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NEW_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsNewExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsNewExpression")
                .field("new_token", &support::DebugSyntaxResult(self.new_token()))
                .field("callee", &support::DebugSyntaxResult(self.callee()))
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .field(
                    "arguments",
                    &support::DebugOptionalElement(self.arguments()),
                )
                .finish()
        } else {
            f.debug_struct("JsNewExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsNewExpression> for SyntaxNode {
    fn from(n: JsNewExpression) -> Self {
        n.syntax
    }
}
impl From<JsNewExpression> for SyntaxElement {
    fn from(n: JsNewExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsNewTargetExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NEW_TARGET_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NEW_TARGET_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsNewTargetExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsNewTargetExpression")
                .field("new_token", &support::DebugSyntaxResult(self.new_token()))
                .field("dot_token", &support::DebugSyntaxResult(self.dot_token()))
                .field(
                    "target_token",
                    &support::DebugSyntaxResult(self.target_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsNewTargetExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsNewTargetExpression> for SyntaxNode {
    fn from(n: JsNewTargetExpression) -> Self {
        n.syntax
    }
}
impl From<JsNewTargetExpression> for SyntaxElement {
    fn from(n: JsNewTargetExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsNullLiteralExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NULL_LITERAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NULL_LITERAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsNullLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsNullLiteralExpression")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsNullLiteralExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsNullLiteralExpression> for SyntaxNode {
    fn from(n: JsNullLiteralExpression) -> Self {
        n.syntax
    }
}
impl From<JsNullLiteralExpression> for SyntaxElement {
    fn from(n: JsNullLiteralExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsNumberLiteralExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NUMBER_LITERAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NUMBER_LITERAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsNumberLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsNumberLiteralExpression")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsNumberLiteralExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsNumberLiteralExpression> for SyntaxNode {
    fn from(n: JsNumberLiteralExpression) -> Self {
        n.syntax
    }
}
impl From<JsNumberLiteralExpression> for SyntaxElement {
    fn from(n: JsNumberLiteralExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectAssignmentPattern {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_ASSIGNMENT_PATTERN as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_ASSIGNMENT_PATTERN
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectAssignmentPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectAssignmentPattern")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("properties", &self.properties())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsObjectAssignmentPattern").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectAssignmentPattern> for SyntaxNode {
    fn from(n: JsObjectAssignmentPattern) -> Self {
        n.syntax
    }
}
impl From<JsObjectAssignmentPattern> for SyntaxElement {
    fn from(n: JsObjectAssignmentPattern) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectAssignmentPatternProperty {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_ASSIGNMENT_PATTERN_PROPERTY as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_ASSIGNMENT_PATTERN_PROPERTY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectAssignmentPatternProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectAssignmentPatternProperty")
                .field("member", &support::DebugSyntaxResult(self.member()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("pattern", &support::DebugSyntaxResult(self.pattern()))
                .field("init", &support::DebugOptionalElement(self.init()))
                .finish()
        } else {
            f.debug_struct("JsObjectAssignmentPatternProperty").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectAssignmentPatternProperty> for SyntaxNode {
    fn from(n: JsObjectAssignmentPatternProperty) -> Self {
        n.syntax
    }
}
impl From<JsObjectAssignmentPatternProperty> for SyntaxElement {
    fn from(n: JsObjectAssignmentPatternProperty) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectAssignmentPatternRest {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_ASSIGNMENT_PATTERN_REST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_ASSIGNMENT_PATTERN_REST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectAssignmentPatternRest {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectAssignmentPatternRest")
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("target", &support::DebugSyntaxResult(self.target()))
                .finish()
        } else {
            f.debug_struct("JsObjectAssignmentPatternRest").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectAssignmentPatternRest> for SyntaxNode {
    fn from(n: JsObjectAssignmentPatternRest) -> Self {
        n.syntax
    }
}
impl From<JsObjectAssignmentPatternRest> for SyntaxElement {
    fn from(n: JsObjectAssignmentPatternRest) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectAssignmentPatternShorthandProperty {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        JS_OBJECT_ASSIGNMENT_PATTERN_SHORTHAND_PROPERTY as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_ASSIGNMENT_PATTERN_SHORTHAND_PROPERTY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectAssignmentPatternShorthandProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectAssignmentPatternShorthandProperty")
                .field("identifier", &support::DebugSyntaxResult(self.identifier()))
                .field("init", &support::DebugOptionalElement(self.init()))
                .finish()
        } else {
            f.debug_struct("JsObjectAssignmentPatternShorthandProperty")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectAssignmentPatternShorthandProperty> for SyntaxNode {
    fn from(n: JsObjectAssignmentPatternShorthandProperty) -> Self {
        n.syntax
    }
}
impl From<JsObjectAssignmentPatternShorthandProperty> for SyntaxElement {
    fn from(n: JsObjectAssignmentPatternShorthandProperty) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectBindingPattern {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_BINDING_PATTERN as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_BINDING_PATTERN
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectBindingPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectBindingPattern")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("properties", &self.properties())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsObjectBindingPattern").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectBindingPattern> for SyntaxNode {
    fn from(n: JsObjectBindingPattern) -> Self {
        n.syntax
    }
}
impl From<JsObjectBindingPattern> for SyntaxElement {
    fn from(n: JsObjectBindingPattern) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectBindingPatternProperty {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_BINDING_PATTERN_PROPERTY as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_BINDING_PATTERN_PROPERTY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectBindingPatternProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectBindingPatternProperty")
                .field("member", &support::DebugSyntaxResult(self.member()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("pattern", &support::DebugSyntaxResult(self.pattern()))
                .field("init", &support::DebugOptionalElement(self.init()))
                .finish()
        } else {
            f.debug_struct("JsObjectBindingPatternProperty").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectBindingPatternProperty> for SyntaxNode {
    fn from(n: JsObjectBindingPatternProperty) -> Self {
        n.syntax
    }
}
impl From<JsObjectBindingPatternProperty> for SyntaxElement {
    fn from(n: JsObjectBindingPatternProperty) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectBindingPatternRest {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_BINDING_PATTERN_REST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_BINDING_PATTERN_REST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectBindingPatternRest {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectBindingPatternRest")
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("binding", &support::DebugSyntaxResult(self.binding()))
                .finish()
        } else {
            f.debug_struct("JsObjectBindingPatternRest").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectBindingPatternRest> for SyntaxNode {
    fn from(n: JsObjectBindingPatternRest) -> Self {
        n.syntax
    }
}
impl From<JsObjectBindingPatternRest> for SyntaxElement {
    fn from(n: JsObjectBindingPatternRest) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectBindingPatternShorthandProperty {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        JS_OBJECT_BINDING_PATTERN_SHORTHAND_PROPERTY as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_BINDING_PATTERN_SHORTHAND_PROPERTY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectBindingPatternShorthandProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectBindingPatternShorthandProperty")
                .field("identifier", &support::DebugSyntaxResult(self.identifier()))
                .field("init", &support::DebugOptionalElement(self.init()))
                .finish()
        } else {
            f.debug_struct("JsObjectBindingPatternShorthandProperty")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectBindingPatternShorthandProperty> for SyntaxNode {
    fn from(n: JsObjectBindingPatternShorthandProperty) -> Self {
        n.syntax
    }
}
impl From<JsObjectBindingPatternShorthandProperty> for SyntaxElement {
    fn from(n: JsObjectBindingPatternShorthandProperty) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsObjectExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsObjectExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsObjectExpression")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("members", &self.members())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsObjectExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsObjectExpression> for SyntaxNode {
    fn from(n: JsObjectExpression) -> Self {
        n.syntax
    }
}
impl From<JsObjectExpression> for SyntaxElement {
    fn from(n: JsObjectExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsParameters {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PARAMETERS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PARAMETERS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsParameters")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("items", &self.items())
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsParameters").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsParameters> for SyntaxNode {
    fn from(n: JsParameters) -> Self {
        n.syntax
    }
}
impl From<JsParameters> for SyntaxElement {
    fn from(n: JsParameters) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsParenthesizedAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PARENTHESIZED_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PARENTHESIZED_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsParenthesizedAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsParenthesizedAssignment")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("assignment", &support::DebugSyntaxResult(self.assignment()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsParenthesizedAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsParenthesizedAssignment> for SyntaxNode {
    fn from(n: JsParenthesizedAssignment) -> Self {
        n.syntax
    }
}
impl From<JsParenthesizedAssignment> for SyntaxElement {
    fn from(n: JsParenthesizedAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsParenthesizedExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PARENTHESIZED_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PARENTHESIZED_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsParenthesizedExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsParenthesizedExpression")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsParenthesizedExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsParenthesizedExpression> for SyntaxNode {
    fn from(n: JsParenthesizedExpression) -> Self {
        n.syntax
    }
}
impl From<JsParenthesizedExpression> for SyntaxElement {
    fn from(n: JsParenthesizedExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsPostUpdateExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_POST_UPDATE_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_POST_UPDATE_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsPostUpdateExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsPostUpdateExpression")
                .field("operand", &support::DebugSyntaxResult(self.operand()))
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsPostUpdateExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsPostUpdateExpression> for SyntaxNode {
    fn from(n: JsPostUpdateExpression) -> Self {
        n.syntax
    }
}
impl From<JsPostUpdateExpression> for SyntaxElement {
    fn from(n: JsPostUpdateExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsPreUpdateExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PRE_UPDATE_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PRE_UPDATE_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsPreUpdateExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsPreUpdateExpression")
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .field("operand", &support::DebugSyntaxResult(self.operand()))
                .finish()
        } else {
            f.debug_struct("JsPreUpdateExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsPreUpdateExpression> for SyntaxNode {
    fn from(n: JsPreUpdateExpression) -> Self {
        n.syntax
    }
}
impl From<JsPreUpdateExpression> for SyntaxElement {
    fn from(n: JsPreUpdateExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsPrivateClassMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PRIVATE_CLASS_MEMBER_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PRIVATE_CLASS_MEMBER_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsPrivateClassMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsPrivateClassMemberName")
                .field("hash_token", &support::DebugSyntaxResult(self.hash_token()))
                .field("id_token", &support::DebugSyntaxResult(self.id_token()))
                .finish()
        } else {
            f.debug_struct("JsPrivateClassMemberName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsPrivateClassMemberName> for SyntaxNode {
    fn from(n: JsPrivateClassMemberName) -> Self {
        n.syntax
    }
}
impl From<JsPrivateClassMemberName> for SyntaxElement {
    fn from(n: JsPrivateClassMemberName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsPrivateName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PRIVATE_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PRIVATE_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsPrivateName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsPrivateName")
                .field("hash_token", &support::DebugSyntaxResult(self.hash_token()))
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsPrivateName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsPrivateName> for SyntaxNode {
    fn from(n: JsPrivateName) -> Self {
        n.syntax
    }
}
impl From<JsPrivateName> for SyntaxElement {
    fn from(n: JsPrivateName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsPropertyClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PROPERTY_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PROPERTY_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsPropertyClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsPropertyClassMember")
                .field("modifiers", &self.modifiers())
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "property_annotation",
                    &support::DebugOptionalElement(self.property_annotation()),
                )
                .field("value", &support::DebugOptionalElement(self.value()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsPropertyClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsPropertyClassMember> for SyntaxNode {
    fn from(n: JsPropertyClassMember) -> Self {
        n.syntax
    }
}
impl From<JsPropertyClassMember> for SyntaxElement {
    fn from(n: JsPropertyClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsPropertyObjectMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PROPERTY_OBJECT_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PROPERTY_OBJECT_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsPropertyObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsPropertyObjectMember")
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("value", &support::DebugSyntaxResult(self.value()))
                .finish()
        } else {
            f.debug_struct("JsPropertyObjectMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsPropertyObjectMember> for SyntaxNode {
    fn from(n: JsPropertyObjectMember) -> Self {
        n.syntax
    }
}
impl From<JsPropertyObjectMember> for SyntaxElement {
    fn from(n: JsPropertyObjectMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsReferenceIdentifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_REFERENCE_IDENTIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_REFERENCE_IDENTIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsReferenceIdentifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsReferenceIdentifier")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsReferenceIdentifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsReferenceIdentifier> for SyntaxNode {
    fn from(n: JsReferenceIdentifier) -> Self {
        n.syntax
    }
}
impl From<JsReferenceIdentifier> for SyntaxElement {
    fn from(n: JsReferenceIdentifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsRegexLiteralExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_REGEX_LITERAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_REGEX_LITERAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsRegexLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsRegexLiteralExpression")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsRegexLiteralExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsRegexLiteralExpression> for SyntaxNode {
    fn from(n: JsRegexLiteralExpression) -> Self {
        n.syntax
    }
}
impl From<JsRegexLiteralExpression> for SyntaxElement {
    fn from(n: JsRegexLiteralExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsRestParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_REST_PARAMETER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_REST_PARAMETER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsRestParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsRestParameter")
                .field("decorators", &self.decorators())
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("binding", &support::DebugSyntaxResult(self.binding()))
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .finish()
        } else {
            f.debug_struct("JsRestParameter").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsRestParameter> for SyntaxNode {
    fn from(n: JsRestParameter) -> Self {
        n.syntax
    }
}
impl From<JsRestParameter> for SyntaxElement {
    fn from(n: JsRestParameter) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsReturnStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_RETURN_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_RETURN_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsReturnStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsReturnStatement")
                .field(
                    "return_token",
                    &support::DebugSyntaxResult(self.return_token()),
                )
                .field("argument", &support::DebugOptionalElement(self.argument()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsReturnStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsReturnStatement> for SyntaxNode {
    fn from(n: JsReturnStatement) -> Self {
        n.syntax
    }
}
impl From<JsReturnStatement> for SyntaxElement {
    fn from(n: JsReturnStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsScript {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SCRIPT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SCRIPT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsScript {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsScript")
                .field(
                    "bom_token",
                    &support::DebugOptionalElement(self.bom_token()),
                )
                .field(
                    "interpreter_token",
                    &support::DebugOptionalElement(self.interpreter_token()),
                )
                .field("directives", &self.directives())
                .field("statements", &self.statements())
                .field("eof_token", &support::DebugSyntaxResult(self.eof_token()))
                .finish()
        } else {
            f.debug_struct("JsScript").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsScript> for SyntaxNode {
    fn from(n: JsScript) -> Self {
        n.syntax
    }
}
impl From<JsScript> for SyntaxElement {
    fn from(n: JsScript) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsSequenceExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SEQUENCE_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SEQUENCE_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsSequenceExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsSequenceExpression")
                .field("left", &support::DebugSyntaxResult(self.left()))
                .field(
                    "comma_token",
                    &support::DebugSyntaxResult(self.comma_token()),
                )
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("JsSequenceExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsSequenceExpression> for SyntaxNode {
    fn from(n: JsSequenceExpression) -> Self {
        n.syntax
    }
}
impl From<JsSequenceExpression> for SyntaxElement {
    fn from(n: JsSequenceExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsSetterClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SETTER_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SETTER_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsSetterClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsSetterClassMember")
                .field("modifiers", &self.modifiers())
                .field("set_token", &support::DebugSyntaxResult(self.set_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("parameter", &support::DebugSyntaxResult(self.parameter()))
                .field(
                    "comma_token",
                    &support::DebugOptionalElement(self.comma_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsSetterClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsSetterClassMember> for SyntaxNode {
    fn from(n: JsSetterClassMember) -> Self {
        n.syntax
    }
}
impl From<JsSetterClassMember> for SyntaxElement {
    fn from(n: JsSetterClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsSetterObjectMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SETTER_OBJECT_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SETTER_OBJECT_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsSetterObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsSetterObjectMember")
                .field("set_token", &support::DebugSyntaxResult(self.set_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("parameter", &support::DebugSyntaxResult(self.parameter()))
                .field(
                    "comma_token",
                    &support::DebugOptionalElement(self.comma_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsSetterObjectMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsSetterObjectMember> for SyntaxNode {
    fn from(n: JsSetterObjectMember) -> Self {
        n.syntax
    }
}
impl From<JsSetterObjectMember> for SyntaxElement {
    fn from(n: JsSetterObjectMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsShorthandNamedImportSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SHORTHAND_NAMED_IMPORT_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SHORTHAND_NAMED_IMPORT_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsShorthandNamedImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsShorthandNamedImportSpecifier")
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field("local_name", &support::DebugSyntaxResult(self.local_name()))
                .finish()
        } else {
            f.debug_struct("JsShorthandNamedImportSpecifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsShorthandNamedImportSpecifier> for SyntaxNode {
    fn from(n: JsShorthandNamedImportSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsShorthandNamedImportSpecifier> for SyntaxElement {
    fn from(n: JsShorthandNamedImportSpecifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsShorthandPropertyObjectMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SHORTHAND_PROPERTY_OBJECT_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SHORTHAND_PROPERTY_OBJECT_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsShorthandPropertyObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsShorthandPropertyObjectMember")
                .field("name", &support::DebugSyntaxResult(self.name()))
                .finish()
        } else {
            f.debug_struct("JsShorthandPropertyObjectMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsShorthandPropertyObjectMember> for SyntaxNode {
    fn from(n: JsShorthandPropertyObjectMember) -> Self {
        n.syntax
    }
}
impl From<JsShorthandPropertyObjectMember> for SyntaxElement {
    fn from(n: JsShorthandPropertyObjectMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsSpread {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SPREAD as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SPREAD
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsSpread {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsSpread")
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("argument", &support::DebugSyntaxResult(self.argument()))
                .finish()
        } else {
            f.debug_struct("JsSpread").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsSpread> for SyntaxNode {
    fn from(n: JsSpread) -> Self {
        n.syntax
    }
}
impl From<JsSpread> for SyntaxElement {
    fn from(n: JsSpread) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsStaticInitializationBlockClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        JS_STATIC_INITIALIZATION_BLOCK_CLASS_MEMBER as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_STATIC_INITIALIZATION_BLOCK_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsStaticInitializationBlockClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsStaticInitializationBlockClassMember")
                .field(
                    "static_token",
                    &support::DebugSyntaxResult(self.static_token()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("statements", &self.statements())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsStaticInitializationBlockClassMember")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsStaticInitializationBlockClassMember> for SyntaxNode {
    fn from(n: JsStaticInitializationBlockClassMember) -> Self {
        n.syntax
    }
}
impl From<JsStaticInitializationBlockClassMember> for SyntaxElement {
    fn from(n: JsStaticInitializationBlockClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsStaticMemberAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_STATIC_MEMBER_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_STATIC_MEMBER_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsStaticMemberAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsStaticMemberAssignment")
                .field("object", &support::DebugSyntaxResult(self.object()))
                .field("dot_token", &support::DebugSyntaxResult(self.dot_token()))
                .field("member", &support::DebugSyntaxResult(self.member()))
                .finish()
        } else {
            f.debug_struct("JsStaticMemberAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsStaticMemberAssignment> for SyntaxNode {
    fn from(n: JsStaticMemberAssignment) -> Self {
        n.syntax
    }
}
impl From<JsStaticMemberAssignment> for SyntaxElement {
    fn from(n: JsStaticMemberAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsStaticMemberExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_STATIC_MEMBER_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_STATIC_MEMBER_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsStaticMemberExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsStaticMemberExpression")
                .field("object", &support::DebugSyntaxResult(self.object()))
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .field("member", &support::DebugSyntaxResult(self.member()))
                .finish()
        } else {
            f.debug_struct("JsStaticMemberExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsStaticMemberExpression> for SyntaxNode {
    fn from(n: JsStaticMemberExpression) -> Self {
        n.syntax
    }
}
impl From<JsStaticMemberExpression> for SyntaxElement {
    fn from(n: JsStaticMemberExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsStaticModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_STATIC_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_STATIC_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsStaticModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsStaticModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsStaticModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsStaticModifier> for SyntaxNode {
    fn from(n: JsStaticModifier) -> Self {
        n.syntax
    }
}
impl From<JsStaticModifier> for SyntaxElement {
    fn from(n: JsStaticModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsStringLiteralExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_STRING_LITERAL_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_STRING_LITERAL_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsStringLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsStringLiteralExpression")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsStringLiteralExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsStringLiteralExpression> for SyntaxNode {
    fn from(n: JsStringLiteralExpression) -> Self {
        n.syntax
    }
}
impl From<JsStringLiteralExpression> for SyntaxElement {
    fn from(n: JsStringLiteralExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsSuperExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SUPER_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SUPER_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsSuperExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsSuperExpression")
                .field(
                    "super_token",
                    &support::DebugSyntaxResult(self.super_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsSuperExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsSuperExpression> for SyntaxNode {
    fn from(n: JsSuperExpression) -> Self {
        n.syntax
    }
}
impl From<JsSuperExpression> for SyntaxElement {
    fn from(n: JsSuperExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsSwitchStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SWITCH_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SWITCH_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsSwitchStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsSwitchStatement")
                .field(
                    "switch_token",
                    &support::DebugSyntaxResult(self.switch_token()),
                )
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "discriminant",
                    &support::DebugSyntaxResult(self.discriminant()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("cases", &self.cases())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsSwitchStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsSwitchStatement> for SyntaxNode {
    fn from(n: JsSwitchStatement) -> Self {
        n.syntax
    }
}
impl From<JsSwitchStatement> for SyntaxElement {
    fn from(n: JsSwitchStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsTemplateChunkElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_TEMPLATE_CHUNK_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_TEMPLATE_CHUNK_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsTemplateChunkElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsTemplateChunkElement")
                .field(
                    "template_chunk_token",
                    &support::DebugSyntaxResult(self.template_chunk_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsTemplateChunkElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsTemplateChunkElement> for SyntaxNode {
    fn from(n: JsTemplateChunkElement) -> Self {
        n.syntax
    }
}
impl From<JsTemplateChunkElement> for SyntaxElement {
    fn from(n: JsTemplateChunkElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsTemplateElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_TEMPLATE_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_TEMPLATE_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsTemplateElement")
                .field(
                    "dollar_curly_token",
                    &support::DebugSyntaxResult(self.dollar_curly_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsTemplateElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsTemplateElement> for SyntaxNode {
    fn from(n: JsTemplateElement) -> Self {
        n.syntax
    }
}
impl From<JsTemplateElement> for SyntaxElement {
    fn from(n: JsTemplateElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsTemplateExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_TEMPLATE_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_TEMPLATE_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsTemplateExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsTemplateExpression")
                .field("tag", &support::DebugOptionalElement(self.tag()))
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .field(
                    "l_tick_token",
                    &support::DebugSyntaxResult(self.l_tick_token()),
                )
                .field("elements", &self.elements())
                .field(
                    "r_tick_token",
                    &support::DebugSyntaxResult(self.r_tick_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsTemplateExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsTemplateExpression> for SyntaxNode {
    fn from(n: JsTemplateExpression) -> Self {
        n.syntax
    }
}
impl From<JsTemplateExpression> for SyntaxElement {
    fn from(n: JsTemplateExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsThisExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_THIS_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_THIS_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsThisExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsThisExpression")
                .field("this_token", &support::DebugSyntaxResult(self.this_token()))
                .finish()
        } else {
            f.debug_struct("JsThisExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsThisExpression> for SyntaxNode {
    fn from(n: JsThisExpression) -> Self {
        n.syntax
    }
}
impl From<JsThisExpression> for SyntaxElement {
    fn from(n: JsThisExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsThrowStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_THROW_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_THROW_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsThrowStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsThrowStatement")
                .field(
                    "throw_token",
                    &support::DebugSyntaxResult(self.throw_token()),
                )
                .field("argument", &support::DebugSyntaxResult(self.argument()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsThrowStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsThrowStatement> for SyntaxNode {
    fn from(n: JsThrowStatement) -> Self {
        n.syntax
    }
}
impl From<JsThrowStatement> for SyntaxElement {
    fn from(n: JsThrowStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsTryFinallyStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_TRY_FINALLY_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_TRY_FINALLY_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsTryFinallyStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsTryFinallyStatement")
                .field("try_token", &support::DebugSyntaxResult(self.try_token()))
                .field("body", &support::DebugSyntaxResult(self.body()))
                .field(
                    "catch_clause",
                    &support::DebugOptionalElement(self.catch_clause()),
                )
                .field(
                    "finally_clause",
                    &support::DebugSyntaxResult(self.finally_clause()),
                )
                .finish()
        } else {
            f.debug_struct("JsTryFinallyStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsTryFinallyStatement> for SyntaxNode {
    fn from(n: JsTryFinallyStatement) -> Self {
        n.syntax
    }
}
impl From<JsTryFinallyStatement> for SyntaxElement {
    fn from(n: JsTryFinallyStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsTryStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_TRY_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_TRY_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsTryStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsTryStatement")
                .field("try_token", &support::DebugSyntaxResult(self.try_token()))
                .field("body", &support::DebugSyntaxResult(self.body()))
                .field(
                    "catch_clause",
                    &support::DebugSyntaxResult(self.catch_clause()),
                )
                .finish()
        } else {
            f.debug_struct("JsTryStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsTryStatement> for SyntaxNode {
    fn from(n: JsTryStatement) -> Self {
        n.syntax
    }
}
impl From<JsTryStatement> for SyntaxElement {
    fn from(n: JsTryStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsUnaryExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_UNARY_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_UNARY_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsUnaryExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsUnaryExpression")
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .field("argument", &support::DebugSyntaxResult(self.argument()))
                .finish()
        } else {
            f.debug_struct("JsUnaryExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsUnaryExpression> for SyntaxNode {
    fn from(n: JsUnaryExpression) -> Self {
        n.syntax
    }
}
impl From<JsUnaryExpression> for SyntaxElement {
    fn from(n: JsUnaryExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsVariableDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_VARIABLE_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_VARIABLE_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsVariableDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsVariableDeclaration")
                .field(
                    "await_token",
                    &support::DebugOptionalElement(self.await_token()),
                )
                .field("kind", &support::DebugSyntaxResult(self.kind()))
                .field("declarators", &self.declarators())
                .finish()
        } else {
            f.debug_struct("JsVariableDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsVariableDeclaration> for SyntaxNode {
    fn from(n: JsVariableDeclaration) -> Self {
        n.syntax
    }
}
impl From<JsVariableDeclaration> for SyntaxElement {
    fn from(n: JsVariableDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsVariableDeclarationClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_VARIABLE_DECLARATION_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_VARIABLE_DECLARATION_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsVariableDeclarationClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsVariableDeclarationClause")
                .field(
                    "declaration",
                    &support::DebugSyntaxResult(self.declaration()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsVariableDeclarationClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsVariableDeclarationClause> for SyntaxNode {
    fn from(n: JsVariableDeclarationClause) -> Self {
        n.syntax
    }
}
impl From<JsVariableDeclarationClause> for SyntaxElement {
    fn from(n: JsVariableDeclarationClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsVariableDeclarator {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_VARIABLE_DECLARATOR as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_VARIABLE_DECLARATOR
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsVariableDeclarator {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsVariableDeclarator")
                .field("id", &support::DebugSyntaxResult(self.id()))
                .field(
                    "variable_annotation",
                    &support::DebugOptionalElement(self.variable_annotation()),
                )
                .field(
                    "initializer",
                    &support::DebugOptionalElement(self.initializer()),
                )
                .finish()
        } else {
            f.debug_struct("JsVariableDeclarator").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsVariableDeclarator> for SyntaxNode {
    fn from(n: JsVariableDeclarator) -> Self {
        n.syntax
    }
}
impl From<JsVariableDeclarator> for SyntaxElement {
    fn from(n: JsVariableDeclarator) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsVariableStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_VARIABLE_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_VARIABLE_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsVariableStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsVariableStatement")
                .field(
                    "declaration",
                    &support::DebugSyntaxResult(self.declaration()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsVariableStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsVariableStatement> for SyntaxNode {
    fn from(n: JsVariableStatement) -> Self {
        n.syntax
    }
}
impl From<JsVariableStatement> for SyntaxElement {
    fn from(n: JsVariableStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsWhileStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_WHILE_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_WHILE_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsWhileStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsWhileStatement")
                .field(
                    "while_token",
                    &support::DebugSyntaxResult(self.while_token()),
                )
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("test", &support::DebugSyntaxResult(self.test()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsWhileStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsWhileStatement> for SyntaxNode {
    fn from(n: JsWhileStatement) -> Self {
        n.syntax
    }
}
impl From<JsWhileStatement> for SyntaxElement {
    fn from(n: JsWhileStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsWithStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_WITH_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_WITH_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsWithStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsWithStatement")
                .field("with_token", &support::DebugSyntaxResult(self.with_token()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("object", &support::DebugSyntaxResult(self.object()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("JsWithStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsWithStatement> for SyntaxNode {
    fn from(n: JsWithStatement) -> Self {
        n.syntax
    }
}
impl From<JsWithStatement> for SyntaxElement {
    fn from(n: JsWithStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsYieldArgument {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_YIELD_ARGUMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_YIELD_ARGUMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsYieldArgument {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsYieldArgument")
                .field(
                    "star_token",
                    &support::DebugOptionalElement(self.star_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .finish()
        } else {
            f.debug_struct("JsYieldArgument").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsYieldArgument> for SyntaxNode {
    fn from(n: JsYieldArgument) -> Self {
        n.syntax
    }
}
impl From<JsYieldArgument> for SyntaxElement {
    fn from(n: JsYieldArgument) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsYieldExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_YIELD_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_YIELD_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsYieldExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsYieldExpression")
                .field(
                    "yield_token",
                    &support::DebugSyntaxResult(self.yield_token()),
                )
                .field("argument", &support::DebugOptionalElement(self.argument()))
                .finish()
        } else {
            f.debug_struct("JsYieldExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsYieldExpression> for SyntaxNode {
    fn from(n: JsYieldExpression) -> Self {
        n.syntax
    }
}
impl From<JsYieldExpression> for SyntaxElement {
    fn from(n: JsYieldExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxAttribute {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_ATTRIBUTE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_ATTRIBUTE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxAttribute {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxAttribute")
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "initializer",
                    &support::DebugOptionalElement(self.initializer()),
                )
                .finish()
        } else {
            f.debug_struct("JsxAttribute").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxAttribute> for SyntaxNode {
    fn from(n: JsxAttribute) -> Self {
        n.syntax
    }
}
impl From<JsxAttribute> for SyntaxElement {
    fn from(n: JsxAttribute) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxAttributeInitializerClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_ATTRIBUTE_INITIALIZER_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_ATTRIBUTE_INITIALIZER_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxAttributeInitializerClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxAttributeInitializerClause")
                .field("eq_token", &support::DebugSyntaxResult(self.eq_token()))
                .field("value", &support::DebugSyntaxResult(self.value()))
                .finish()
        } else {
            f.debug_struct("JsxAttributeInitializerClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxAttributeInitializerClause> for SyntaxNode {
    fn from(n: JsxAttributeInitializerClause) -> Self {
        n.syntax
    }
}
impl From<JsxAttributeInitializerClause> for SyntaxElement {
    fn from(n: JsxAttributeInitializerClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxClosingElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_CLOSING_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_CLOSING_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxClosingElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxClosingElement")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field(
                    "slash_token",
                    &support::DebugSyntaxResult(self.slash_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxClosingElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxClosingElement> for SyntaxNode {
    fn from(n: JsxClosingElement) -> Self {
        n.syntax
    }
}
impl From<JsxClosingElement> for SyntaxElement {
    fn from(n: JsxClosingElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxClosingFragment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_CLOSING_FRAGMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_CLOSING_FRAGMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxClosingFragment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxClosingFragment")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field(
                    "slash_token",
                    &support::DebugSyntaxResult(self.slash_token()),
                )
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxClosingFragment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxClosingFragment> for SyntaxNode {
    fn from(n: JsxClosingFragment) -> Self {
        n.syntax
    }
}
impl From<JsxClosingFragment> for SyntaxElement {
    fn from(n: JsxClosingFragment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxElement")
                .field(
                    "opening_element",
                    &support::DebugSyntaxResult(self.opening_element()),
                )
                .field("children", &self.children())
                .field(
                    "closing_element",
                    &support::DebugSyntaxResult(self.closing_element()),
                )
                .finish()
        } else {
            f.debug_struct("JsxElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxElement> for SyntaxNode {
    fn from(n: JsxElement) -> Self {
        n.syntax
    }
}
impl From<JsxElement> for SyntaxElement {
    fn from(n: JsxElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxExpressionAttributeValue {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_EXPRESSION_ATTRIBUTE_VALUE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_EXPRESSION_ATTRIBUTE_VALUE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxExpressionAttributeValue {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxExpressionAttributeValue")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxExpressionAttributeValue").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxExpressionAttributeValue> for SyntaxNode {
    fn from(n: JsxExpressionAttributeValue) -> Self {
        n.syntax
    }
}
impl From<JsxExpressionAttributeValue> for SyntaxElement {
    fn from(n: JsxExpressionAttributeValue) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxExpressionChild {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_EXPRESSION_CHILD as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_EXPRESSION_CHILD
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxExpressionChild {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxExpressionChild")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field(
                    "expression",
                    &support::DebugOptionalElement(self.expression()),
                )
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxExpressionChild").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxExpressionChild> for SyntaxNode {
    fn from(n: JsxExpressionChild) -> Self {
        n.syntax
    }
}
impl From<JsxExpressionChild> for SyntaxElement {
    fn from(n: JsxExpressionChild) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxFragment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_FRAGMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_FRAGMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxFragment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxFragment")
                .field(
                    "opening_fragment",
                    &support::DebugSyntaxResult(self.opening_fragment()),
                )
                .field("children", &self.children())
                .field(
                    "closing_fragment",
                    &support::DebugSyntaxResult(self.closing_fragment()),
                )
                .finish()
        } else {
            f.debug_struct("JsxFragment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxFragment> for SyntaxNode {
    fn from(n: JsxFragment) -> Self {
        n.syntax
    }
}
impl From<JsxFragment> for SyntaxElement {
    fn from(n: JsxFragment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_MEMBER_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_MEMBER_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxMemberName")
                .field("object", &support::DebugSyntaxResult(self.object()))
                .field("dot_token", &support::DebugSyntaxResult(self.dot_token()))
                .field("member", &support::DebugSyntaxResult(self.member()))
                .finish()
        } else {
            f.debug_struct("JsxMemberName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxMemberName> for SyntaxNode {
    fn from(n: JsxMemberName) -> Self {
        n.syntax
    }
}
impl From<JsxMemberName> for SyntaxElement {
    fn from(n: JsxMemberName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxName")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxName> for SyntaxNode {
    fn from(n: JsxName) -> Self {
        n.syntax
    }
}
impl From<JsxName> for SyntaxElement {
    fn from(n: JsxName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxNamespaceName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_NAMESPACE_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_NAMESPACE_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxNamespaceName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxNamespaceName")
                .field("namespace", &support::DebugSyntaxResult(self.namespace()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .finish()
        } else {
            f.debug_struct("JsxNamespaceName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxNamespaceName> for SyntaxNode {
    fn from(n: JsxNamespaceName) -> Self {
        n.syntax
    }
}
impl From<JsxNamespaceName> for SyntaxElement {
    fn from(n: JsxNamespaceName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxOpeningElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_OPENING_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_OPENING_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxOpeningElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxOpeningElement")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .field("attributes", &self.attributes())
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxOpeningElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxOpeningElement> for SyntaxNode {
    fn from(n: JsxOpeningElement) -> Self {
        n.syntax
    }
}
impl From<JsxOpeningElement> for SyntaxElement {
    fn from(n: JsxOpeningElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxOpeningFragment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_OPENING_FRAGMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_OPENING_FRAGMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxOpeningFragment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxOpeningFragment")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxOpeningFragment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxOpeningFragment> for SyntaxNode {
    fn from(n: JsxOpeningFragment) -> Self {
        n.syntax
    }
}
impl From<JsxOpeningFragment> for SyntaxElement {
    fn from(n: JsxOpeningFragment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxReferenceIdentifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_REFERENCE_IDENTIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_REFERENCE_IDENTIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxReferenceIdentifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxReferenceIdentifier")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxReferenceIdentifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxReferenceIdentifier> for SyntaxNode {
    fn from(n: JsxReferenceIdentifier) -> Self {
        n.syntax
    }
}
impl From<JsxReferenceIdentifier> for SyntaxElement {
    fn from(n: JsxReferenceIdentifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxSelfClosingElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_SELF_CLOSING_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_SELF_CLOSING_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxSelfClosingElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxSelfClosingElement")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .field("attributes", &self.attributes())
                .field(
                    "slash_token",
                    &support::DebugSyntaxResult(self.slash_token()),
                )
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxSelfClosingElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxSelfClosingElement> for SyntaxNode {
    fn from(n: JsxSelfClosingElement) -> Self {
        n.syntax
    }
}
impl From<JsxSelfClosingElement> for SyntaxElement {
    fn from(n: JsxSelfClosingElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxSpreadAttribute {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_SPREAD_ATTRIBUTE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_SPREAD_ATTRIBUTE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxSpreadAttribute {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxSpreadAttribute")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("argument", &support::DebugSyntaxResult(self.argument()))
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxSpreadAttribute").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxSpreadAttribute> for SyntaxNode {
    fn from(n: JsxSpreadAttribute) -> Self {
        n.syntax
    }
}
impl From<JsxSpreadAttribute> for SyntaxElement {
    fn from(n: JsxSpreadAttribute) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxSpreadChild {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_SPREAD_CHILD as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_SPREAD_CHILD
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxSpreadChild {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxSpreadChild")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxSpreadChild").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxSpreadChild> for SyntaxNode {
    fn from(n: JsxSpreadChild) -> Self {
        n.syntax
    }
}
impl From<JsxSpreadChild> for SyntaxElement {
    fn from(n: JsxSpreadChild) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxString {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_STRING as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_STRING
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxString {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxString")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxString").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxString> for SyntaxNode {
    fn from(n: JsxString) -> Self {
        n.syntax
    }
}
impl From<JsxString> for SyntaxElement {
    fn from(n: JsxString) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxTagExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_TAG_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_TAG_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxTagExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxTagExpression")
                .field("tag", &support::DebugSyntaxResult(self.tag()))
                .finish()
        } else {
            f.debug_struct("JsxTagExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxTagExpression> for SyntaxNode {
    fn from(n: JsxTagExpression) -> Self {
        n.syntax
    }
}
impl From<JsxTagExpression> for SyntaxElement {
    fn from(n: JsxTagExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for JsxText {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_TEXT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_TEXT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsxText {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("JsxText")
                .field(
                    "value_token",
                    &support::DebugSyntaxResult(self.value_token()),
                )
                .finish()
        } else {
            f.debug_struct("JsxText").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<JsxText> for SyntaxNode {
    fn from(n: JsxText) -> Self {
        n.syntax
    }
}
impl From<JsxText> for SyntaxElement {
    fn from(n: JsxText) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsAbstractModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ABSTRACT_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ABSTRACT_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsAbstractModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsAbstractModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsAbstractModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsAbstractModifier> for SyntaxNode {
    fn from(n: TsAbstractModifier) -> Self {
        n.syntax
    }
}
impl From<TsAbstractModifier> for SyntaxElement {
    fn from(n: TsAbstractModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsAccessibilityModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ACCESSIBILITY_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ACCESSIBILITY_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsAccessibilityModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsAccessibilityModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsAccessibilityModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsAccessibilityModifier> for SyntaxNode {
    fn from(n: TsAccessibilityModifier) -> Self {
        n.syntax
    }
}
impl From<TsAccessibilityModifier> for SyntaxElement {
    fn from(n: TsAccessibilityModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsAnyType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ANY_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ANY_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsAnyType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsAnyType")
                .field("any_token", &support::DebugSyntaxResult(self.any_token()))
                .finish()
        } else {
            f.debug_struct("TsAnyType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsAnyType> for SyntaxNode {
    fn from(n: TsAnyType) -> Self {
        n.syntax
    }
}
impl From<TsAnyType> for SyntaxElement {
    fn from(n: TsAnyType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsArrayType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ARRAY_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ARRAY_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsArrayType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsArrayType")
                .field(
                    "element_type",
                    &support::DebugSyntaxResult(self.element_type()),
                )
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsArrayType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsArrayType> for SyntaxNode {
    fn from(n: TsArrayType) -> Self {
        n.syntax
    }
}
impl From<TsArrayType> for SyntaxElement {
    fn from(n: TsArrayType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsAsAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_AS_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_AS_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsAsAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsAsAssignment")
                .field("assignment", &support::DebugSyntaxResult(self.assignment()))
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsAsAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsAsAssignment> for SyntaxNode {
    fn from(n: TsAsAssignment) -> Self {
        n.syntax
    }
}
impl From<TsAsAssignment> for SyntaxElement {
    fn from(n: TsAsAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsAsExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_AS_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_AS_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsAsExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsAsExpression")
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsAsExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsAsExpression> for SyntaxNode {
    fn from(n: TsAsExpression) -> Self {
        n.syntax
    }
}
impl From<TsAsExpression> for SyntaxElement {
    fn from(n: TsAsExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsAssertsCondition {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ASSERTS_CONDITION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ASSERTS_CONDITION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsAssertsCondition {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsAssertsCondition")
                .field("is_token", &support::DebugSyntaxResult(self.is_token()))
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsAssertsCondition").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsAssertsCondition> for SyntaxNode {
    fn from(n: TsAssertsCondition) -> Self {
        n.syntax
    }
}
impl From<TsAssertsCondition> for SyntaxElement {
    fn from(n: TsAssertsCondition) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsAssertsReturnType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ASSERTS_RETURN_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ASSERTS_RETURN_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsAssertsReturnType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsAssertsReturnType")
                .field(
                    "asserts_token",
                    &support::DebugSyntaxResult(self.asserts_token()),
                )
                .field(
                    "parameter_name",
                    &support::DebugSyntaxResult(self.parameter_name()),
                )
                .field(
                    "predicate",
                    &support::DebugOptionalElement(self.predicate()),
                )
                .finish()
        } else {
            f.debug_struct("TsAssertsReturnType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsAssertsReturnType> for SyntaxNode {
    fn from(n: TsAssertsReturnType) -> Self {
        n.syntax
    }
}
impl From<TsAssertsReturnType> for SyntaxElement {
    fn from(n: TsAssertsReturnType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsBigintLiteralType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_BIGINT_LITERAL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_BIGINT_LITERAL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsBigintLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsBigintLiteralType")
                .field(
                    "minus_token",
                    &support::DebugOptionalElement(self.minus_token()),
                )
                .field(
                    "literal_token",
                    &support::DebugSyntaxResult(self.literal_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsBigintLiteralType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsBigintLiteralType> for SyntaxNode {
    fn from(n: TsBigintLiteralType) -> Self {
        n.syntax
    }
}
impl From<TsBigintLiteralType> for SyntaxElement {
    fn from(n: TsBigintLiteralType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsBigintType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_BIGINT_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_BIGINT_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsBigintType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsBigintType")
                .field(
                    "bigint_token",
                    &support::DebugSyntaxResult(self.bigint_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsBigintType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsBigintType> for SyntaxNode {
    fn from(n: TsBigintType) -> Self {
        n.syntax
    }
}
impl From<TsBigintType> for SyntaxElement {
    fn from(n: TsBigintType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsBooleanLiteralType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_BOOLEAN_LITERAL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_BOOLEAN_LITERAL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsBooleanLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsBooleanLiteralType")
                .field("literal", &support::DebugSyntaxResult(self.literal()))
                .finish()
        } else {
            f.debug_struct("TsBooleanLiteralType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsBooleanLiteralType> for SyntaxNode {
    fn from(n: TsBooleanLiteralType) -> Self {
        n.syntax
    }
}
impl From<TsBooleanLiteralType> for SyntaxElement {
    fn from(n: TsBooleanLiteralType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsBooleanType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_BOOLEAN_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_BOOLEAN_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsBooleanType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsBooleanType")
                .field(
                    "boolean_token",
                    &support::DebugSyntaxResult(self.boolean_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsBooleanType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsBooleanType> for SyntaxNode {
    fn from(n: TsBooleanType) -> Self {
        n.syntax
    }
}
impl From<TsBooleanType> for SyntaxElement {
    fn from(n: TsBooleanType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsCallSignatureTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_CALL_SIGNATURE_TYPE_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_CALL_SIGNATURE_TYPE_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsCallSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsCallSignatureTypeMember")
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field(
                    "separator_token",
                    &support::DebugOptionalElement(self.separator_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsCallSignatureTypeMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsCallSignatureTypeMember> for SyntaxNode {
    fn from(n: TsCallSignatureTypeMember) -> Self {
        n.syntax
    }
}
impl From<TsCallSignatureTypeMember> for SyntaxElement {
    fn from(n: TsCallSignatureTypeMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsConditionalType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_CONDITIONAL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_CONDITIONAL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsConditionalType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsConditionalType")
                .field("check_type", &support::DebugSyntaxResult(self.check_type()))
                .field(
                    "extends_token",
                    &support::DebugSyntaxResult(self.extends_token()),
                )
                .field(
                    "extends_type",
                    &support::DebugSyntaxResult(self.extends_type()),
                )
                .field(
                    "question_mark_token",
                    &support::DebugSyntaxResult(self.question_mark_token()),
                )
                .field("true_type", &support::DebugSyntaxResult(self.true_type()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("false_type", &support::DebugSyntaxResult(self.false_type()))
                .finish()
        } else {
            f.debug_struct("TsConditionalType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsConditionalType> for SyntaxNode {
    fn from(n: TsConditionalType) -> Self {
        n.syntax
    }
}
impl From<TsConditionalType> for SyntaxElement {
    fn from(n: TsConditionalType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsConstModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_CONST_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_CONST_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsConstModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsConstModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsConstModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsConstModifier> for SyntaxNode {
    fn from(n: TsConstModifier) -> Self {
        n.syntax
    }
}
impl From<TsConstModifier> for SyntaxElement {
    fn from(n: TsConstModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsConstructSignatureTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_CONSTRUCT_SIGNATURE_TYPE_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_CONSTRUCT_SIGNATURE_TYPE_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsConstructSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsConstructSignatureTypeMember")
                .field("new_token", &support::DebugSyntaxResult(self.new_token()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .field(
                    "separator_token",
                    &support::DebugOptionalElement(self.separator_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsConstructSignatureTypeMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsConstructSignatureTypeMember> for SyntaxNode {
    fn from(n: TsConstructSignatureTypeMember) -> Self {
        n.syntax
    }
}
impl From<TsConstructSignatureTypeMember> for SyntaxElement {
    fn from(n: TsConstructSignatureTypeMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsConstructorSignatureClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_CONSTRUCTOR_SIGNATURE_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_CONSTRUCTOR_SIGNATURE_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsConstructorSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsConstructorSignatureClassMember")
                .field("modifiers", &self.modifiers())
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsConstructorSignatureClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsConstructorSignatureClassMember> for SyntaxNode {
    fn from(n: TsConstructorSignatureClassMember) -> Self {
        n.syntax
    }
}
impl From<TsConstructorSignatureClassMember> for SyntaxElement {
    fn from(n: TsConstructorSignatureClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsConstructorType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_CONSTRUCTOR_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_CONSTRUCTOR_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsConstructorType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsConstructorType")
                .field(
                    "abstract_token",
                    &support::DebugOptionalElement(self.abstract_token()),
                )
                .field("new_token", &support::DebugSyntaxResult(self.new_token()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "fat_arrow_token",
                    &support::DebugSyntaxResult(self.fat_arrow_token()),
                )
                .field(
                    "return_type",
                    &support::DebugSyntaxResult(self.return_type()),
                )
                .finish()
        } else {
            f.debug_struct("TsConstructorType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsConstructorType> for SyntaxNode {
    fn from(n: TsConstructorType) -> Self {
        n.syntax
    }
}
impl From<TsConstructorType> for SyntaxElement {
    fn from(n: TsConstructorType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDeclarationModule {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_DECLARATION_MODULE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DECLARATION_MODULE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDeclarationModule {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDeclarationModule")
                .field(
                    "bom_token",
                    &support::DebugOptionalElement(self.bom_token()),
                )
                .field(
                    "interpreter_token",
                    &support::DebugOptionalElement(self.interpreter_token()),
                )
                .field("directives", &self.directives())
                .field("items", &self.items())
                .field("eof_token", &support::DebugSyntaxResult(self.eof_token()))
                .finish()
        } else {
            f.debug_struct("TsDeclarationModule").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDeclarationModule> for SyntaxNode {
    fn from(n: TsDeclarationModule) -> Self {
        n.syntax
    }
}
impl From<TsDeclarationModule> for SyntaxElement {
    fn from(n: TsDeclarationModule) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDeclareFunctionDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_DECLARE_FUNCTION_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DECLARE_FUNCTION_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDeclareFunctionDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDeclareFunctionDeclaration")
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "function_token",
                    &support::DebugSyntaxResult(self.function_token()),
                )
                .field("id", &support::DebugSyntaxResult(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsDeclareFunctionDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDeclareFunctionDeclaration> for SyntaxNode {
    fn from(n: TsDeclareFunctionDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsDeclareFunctionDeclaration> for SyntaxElement {
    fn from(n: TsDeclareFunctionDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDeclareFunctionExportDefaultDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        TS_DECLARE_FUNCTION_EXPORT_DEFAULT_DECLARATION as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DECLARE_FUNCTION_EXPORT_DEFAULT_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDeclareFunctionExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDeclareFunctionExportDefaultDeclaration")
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field(
                    "function_token",
                    &support::DebugSyntaxResult(self.function_token()),
                )
                .field("id", &support::DebugOptionalElement(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsDeclareFunctionExportDefaultDeclaration")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDeclareFunctionExportDefaultDeclaration> for SyntaxNode {
    fn from(n: TsDeclareFunctionExportDefaultDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsDeclareFunctionExportDefaultDeclaration> for SyntaxElement {
    fn from(n: TsDeclareFunctionExportDefaultDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDeclareModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_DECLARE_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DECLARE_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDeclareModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDeclareModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsDeclareModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDeclareModifier> for SyntaxNode {
    fn from(n: TsDeclareModifier) -> Self {
        n.syntax
    }
}
impl From<TsDeclareModifier> for SyntaxElement {
    fn from(n: TsDeclareModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDeclareStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_DECLARE_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DECLARE_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDeclareStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDeclareStatement")
                .field(
                    "declare_token",
                    &support::DebugSyntaxResult(self.declare_token()),
                )
                .field(
                    "declaration",
                    &support::DebugSyntaxResult(self.declaration()),
                )
                .finish()
        } else {
            f.debug_struct("TsDeclareStatement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDeclareStatement> for SyntaxNode {
    fn from(n: TsDeclareStatement) -> Self {
        n.syntax
    }
}
impl From<TsDeclareStatement> for SyntaxElement {
    fn from(n: TsDeclareStatement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDefaultTypeClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_DEFAULT_TYPE_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DEFAULT_TYPE_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDefaultTypeClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDefaultTypeClause")
                .field("eq_token", &support::DebugSyntaxResult(self.eq_token()))
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsDefaultTypeClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDefaultTypeClause> for SyntaxNode {
    fn from(n: TsDefaultTypeClause) -> Self {
        n.syntax
    }
}
impl From<TsDefaultTypeClause> for SyntaxElement {
    fn from(n: TsDefaultTypeClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDefinitePropertyAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_DEFINITE_PROPERTY_ANNOTATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DEFINITE_PROPERTY_ANNOTATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDefinitePropertyAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDefinitePropertyAnnotation")
                .field("excl_token", &support::DebugSyntaxResult(self.excl_token()))
                .field(
                    "type_annotation",
                    &support::DebugSyntaxResult(self.type_annotation()),
                )
                .finish()
        } else {
            f.debug_struct("TsDefinitePropertyAnnotation").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDefinitePropertyAnnotation> for SyntaxNode {
    fn from(n: TsDefinitePropertyAnnotation) -> Self {
        n.syntax
    }
}
impl From<TsDefinitePropertyAnnotation> for SyntaxElement {
    fn from(n: TsDefinitePropertyAnnotation) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsDefiniteVariableAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_DEFINITE_VARIABLE_ANNOTATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_DEFINITE_VARIABLE_ANNOTATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsDefiniteVariableAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsDefiniteVariableAnnotation")
                .field("excl_token", &support::DebugSyntaxResult(self.excl_token()))
                .field(
                    "type_annotation",
                    &support::DebugSyntaxResult(self.type_annotation()),
                )
                .finish()
        } else {
            f.debug_struct("TsDefiniteVariableAnnotation").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsDefiniteVariableAnnotation> for SyntaxNode {
    fn from(n: TsDefiniteVariableAnnotation) -> Self {
        n.syntax
    }
}
impl From<TsDefiniteVariableAnnotation> for SyntaxElement {
    fn from(n: TsDefiniteVariableAnnotation) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsEmptyExternalModuleDeclarationBody {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        TS_EMPTY_EXTERNAL_MODULE_DECLARATION_BODY as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_EMPTY_EXTERNAL_MODULE_DECLARATION_BODY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsEmptyExternalModuleDeclarationBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsEmptyExternalModuleDeclarationBody")
                .field(
                    "semicolon_token",
                    &support::DebugSyntaxResult(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsEmptyExternalModuleDeclarationBody")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsEmptyExternalModuleDeclarationBody> for SyntaxNode {
    fn from(n: TsEmptyExternalModuleDeclarationBody) -> Self {
        n.syntax
    }
}
impl From<TsEmptyExternalModuleDeclarationBody> for SyntaxElement {
    fn from(n: TsEmptyExternalModuleDeclarationBody) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsEnumDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ENUM_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ENUM_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsEnumDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsEnumDeclaration")
                .field(
                    "const_token",
                    &support::DebugOptionalElement(self.const_token()),
                )
                .field("enum_token", &support::DebugSyntaxResult(self.enum_token()))
                .field("id", &support::DebugSyntaxResult(self.id()))
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("members", &self.members())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsEnumDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsEnumDeclaration> for SyntaxNode {
    fn from(n: TsEnumDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsEnumDeclaration> for SyntaxElement {
    fn from(n: TsEnumDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsEnumMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ENUM_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ENUM_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsEnumMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsEnumMember")
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "initializer",
                    &support::DebugOptionalElement(self.initializer()),
                )
                .finish()
        } else {
            f.debug_struct("TsEnumMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsEnumMember> for SyntaxNode {
    fn from(n: TsEnumMember) -> Self {
        n.syntax
    }
}
impl From<TsEnumMember> for SyntaxElement {
    fn from(n: TsEnumMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsExportAsNamespaceClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_EXPORT_AS_NAMESPACE_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_EXPORT_AS_NAMESPACE_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsExportAsNamespaceClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsExportAsNamespaceClause")
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field(
                    "namespace_token",
                    &support::DebugSyntaxResult(self.namespace_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsExportAsNamespaceClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsExportAsNamespaceClause> for SyntaxNode {
    fn from(n: TsExportAsNamespaceClause) -> Self {
        n.syntax
    }
}
impl From<TsExportAsNamespaceClause> for SyntaxElement {
    fn from(n: TsExportAsNamespaceClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsExportAssignmentClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_EXPORT_ASSIGNMENT_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_EXPORT_ASSIGNMENT_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsExportAssignmentClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsExportAssignmentClause")
                .field("eq_token", &support::DebugSyntaxResult(self.eq_token()))
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsExportAssignmentClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsExportAssignmentClause> for SyntaxNode {
    fn from(n: TsExportAssignmentClause) -> Self {
        n.syntax
    }
}
impl From<TsExportAssignmentClause> for SyntaxElement {
    fn from(n: TsExportAssignmentClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsExportDeclareClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_EXPORT_DECLARE_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_EXPORT_DECLARE_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsExportDeclareClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsExportDeclareClause")
                .field(
                    "declare_token",
                    &support::DebugSyntaxResult(self.declare_token()),
                )
                .field(
                    "declaration",
                    &support::DebugSyntaxResult(self.declaration()),
                )
                .finish()
        } else {
            f.debug_struct("TsExportDeclareClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsExportDeclareClause> for SyntaxNode {
    fn from(n: TsExportDeclareClause) -> Self {
        n.syntax
    }
}
impl From<TsExportDeclareClause> for SyntaxElement {
    fn from(n: TsExportDeclareClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsExtendsClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_EXTENDS_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_EXTENDS_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsExtendsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsExtendsClause")
                .field(
                    "extends_token",
                    &support::DebugSyntaxResult(self.extends_token()),
                )
                .field("types", &self.types())
                .finish()
        } else {
            f.debug_struct("TsExtendsClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsExtendsClause> for SyntaxNode {
    fn from(n: TsExtendsClause) -> Self {
        n.syntax
    }
}
impl From<TsExtendsClause> for SyntaxElement {
    fn from(n: TsExtendsClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsExternalModuleDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_EXTERNAL_MODULE_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_EXTERNAL_MODULE_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsExternalModuleDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsExternalModuleDeclaration")
                .field(
                    "module_token",
                    &support::DebugSyntaxResult(self.module_token()),
                )
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field("body", &support::DebugOptionalElement(self.body()))
                .finish()
        } else {
            f.debug_struct("TsExternalModuleDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsExternalModuleDeclaration> for SyntaxNode {
    fn from(n: TsExternalModuleDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsExternalModuleDeclaration> for SyntaxElement {
    fn from(n: TsExternalModuleDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsExternalModuleReference {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_EXTERNAL_MODULE_REFERENCE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_EXTERNAL_MODULE_REFERENCE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsExternalModuleReference {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsExternalModuleReference")
                .field(
                    "require_token",
                    &support::DebugSyntaxResult(self.require_token()),
                )
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("source", &support::DebugSyntaxResult(self.source()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsExternalModuleReference").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsExternalModuleReference> for SyntaxNode {
    fn from(n: TsExternalModuleReference) -> Self {
        n.syntax
    }
}
impl From<TsExternalModuleReference> for SyntaxElement {
    fn from(n: TsExternalModuleReference) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsFunctionType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_FUNCTION_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_FUNCTION_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsFunctionType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsFunctionType")
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "fat_arrow_token",
                    &support::DebugSyntaxResult(self.fat_arrow_token()),
                )
                .field(
                    "return_type",
                    &support::DebugSyntaxResult(self.return_type()),
                )
                .finish()
        } else {
            f.debug_struct("TsFunctionType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsFunctionType> for SyntaxNode {
    fn from(n: TsFunctionType) -> Self {
        n.syntax
    }
}
impl From<TsFunctionType> for SyntaxElement {
    fn from(n: TsFunctionType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsGetterSignatureClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_GETTER_SIGNATURE_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_GETTER_SIGNATURE_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsGetterSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsGetterSignatureClassMember")
                .field("modifiers", &self.modifiers())
                .field("get_token", &support::DebugSyntaxResult(self.get_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "return_type",
                    &support::DebugOptionalElement(self.return_type()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsGetterSignatureClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsGetterSignatureClassMember> for SyntaxNode {
    fn from(n: TsGetterSignatureClassMember) -> Self {
        n.syntax
    }
}
impl From<TsGetterSignatureClassMember> for SyntaxElement {
    fn from(n: TsGetterSignatureClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsGetterSignatureTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_GETTER_SIGNATURE_TYPE_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_GETTER_SIGNATURE_TYPE_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsGetterSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsGetterSignatureTypeMember")
                .field("get_token", &support::DebugSyntaxResult(self.get_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .field(
                    "separator_token",
                    &support::DebugOptionalElement(self.separator_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsGetterSignatureTypeMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsGetterSignatureTypeMember> for SyntaxNode {
    fn from(n: TsGetterSignatureTypeMember) -> Self {
        n.syntax
    }
}
impl From<TsGetterSignatureTypeMember> for SyntaxElement {
    fn from(n: TsGetterSignatureTypeMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsGlobalDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_GLOBAL_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_GLOBAL_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsGlobalDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsGlobalDeclaration")
                .field(
                    "global_token",
                    &support::DebugSyntaxResult(self.global_token()),
                )
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("TsGlobalDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsGlobalDeclaration> for SyntaxNode {
    fn from(n: TsGlobalDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsGlobalDeclaration> for SyntaxElement {
    fn from(n: TsGlobalDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsIdentifierBinding {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IDENTIFIER_BINDING as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IDENTIFIER_BINDING
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsIdentifierBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsIdentifierBinding")
                .field("name_token", &support::DebugSyntaxResult(self.name_token()))
                .finish()
        } else {
            f.debug_struct("TsIdentifierBinding").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsIdentifierBinding> for SyntaxNode {
    fn from(n: TsIdentifierBinding) -> Self {
        n.syntax
    }
}
impl From<TsIdentifierBinding> for SyntaxElement {
    fn from(n: TsIdentifierBinding) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsImplementsClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IMPLEMENTS_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IMPLEMENTS_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsImplementsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsImplementsClause")
                .field(
                    "implements_token",
                    &support::DebugSyntaxResult(self.implements_token()),
                )
                .field("types", &self.types())
                .finish()
        } else {
            f.debug_struct("TsImplementsClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsImplementsClause> for SyntaxNode {
    fn from(n: TsImplementsClause) -> Self {
        n.syntax
    }
}
impl From<TsImplementsClause> for SyntaxElement {
    fn from(n: TsImplementsClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsImportEqualsDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IMPORT_EQUALS_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IMPORT_EQUALS_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsImportEqualsDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsImportEqualsDeclaration")
                .field(
                    "import_token",
                    &support::DebugSyntaxResult(self.import_token()),
                )
                .field(
                    "type_token",
                    &support::DebugOptionalElement(self.type_token()),
                )
                .field("id", &support::DebugSyntaxResult(self.id()))
                .field("eq_token", &support::DebugSyntaxResult(self.eq_token()))
                .field(
                    "module_reference",
                    &support::DebugSyntaxResult(self.module_reference()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsImportEqualsDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsImportEqualsDeclaration> for SyntaxNode {
    fn from(n: TsImportEqualsDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsImportEqualsDeclaration> for SyntaxElement {
    fn from(n: TsImportEqualsDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsImportType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IMPORT_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IMPORT_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsImportType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsImportType")
                .field(
                    "typeof_token",
                    &support::DebugOptionalElement(self.typeof_token()),
                )
                .field(
                    "import_token",
                    &support::DebugSyntaxResult(self.import_token()),
                )
                .field("arguments", &support::DebugSyntaxResult(self.arguments()))
                .field(
                    "qualifier_clause",
                    &support::DebugOptionalElement(self.qualifier_clause()),
                )
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .finish()
        } else {
            f.debug_struct("TsImportType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsImportType> for SyntaxNode {
    fn from(n: TsImportType) -> Self {
        n.syntax
    }
}
impl From<TsImportType> for SyntaxElement {
    fn from(n: TsImportType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsImportTypeArguments {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IMPORT_TYPE_ARGUMENTS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IMPORT_TYPE_ARGUMENTS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsImportTypeArguments {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsImportTypeArguments")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("argument", &support::DebugSyntaxResult(self.argument()))
                .field(
                    "comma_token",
                    &support::DebugOptionalElement(self.comma_token()),
                )
                .field(
                    "ts_import_type_assertion_block",
                    &support::DebugOptionalElement(self.ts_import_type_assertion_block()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsImportTypeArguments").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsImportTypeArguments> for SyntaxNode {
    fn from(n: TsImportTypeArguments) -> Self {
        n.syntax
    }
}
impl From<TsImportTypeArguments> for SyntaxElement {
    fn from(n: TsImportTypeArguments) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsImportTypeAssertion {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IMPORT_TYPE_ASSERTION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IMPORT_TYPE_ASSERTION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsImportTypeAssertion {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsImportTypeAssertion")
                .field("with_token", &support::DebugSyntaxResult(self.with_token()))
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("assertions", &self.assertions())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsImportTypeAssertion").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsImportTypeAssertion> for SyntaxNode {
    fn from(n: TsImportTypeAssertion) -> Self {
        n.syntax
    }
}
impl From<TsImportTypeAssertion> for SyntaxElement {
    fn from(n: TsImportTypeAssertion) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsImportTypeAssertionBlock {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IMPORT_TYPE_ASSERTION_BLOCK as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IMPORT_TYPE_ASSERTION_BLOCK
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsImportTypeAssertionBlock {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsImportTypeAssertionBlock")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field(
                    "type_assertion",
                    &support::DebugSyntaxResult(self.type_assertion()),
                )
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsImportTypeAssertionBlock").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsImportTypeAssertionBlock> for SyntaxNode {
    fn from(n: TsImportTypeAssertionBlock) -> Self {
        n.syntax
    }
}
impl From<TsImportTypeAssertionBlock> for SyntaxElement {
    fn from(n: TsImportTypeAssertionBlock) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsImportTypeQualifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IMPORT_TYPE_QUALIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IMPORT_TYPE_QUALIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsImportTypeQualifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsImportTypeQualifier")
                .field("dot_token", &support::DebugSyntaxResult(self.dot_token()))
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("TsImportTypeQualifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsImportTypeQualifier> for SyntaxNode {
    fn from(n: TsImportTypeQualifier) -> Self {
        n.syntax
    }
}
impl From<TsImportTypeQualifier> for SyntaxElement {
    fn from(n: TsImportTypeQualifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsInModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_IN_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_IN_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsInModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsInModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsInModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsInModifier> for SyntaxNode {
    fn from(n: TsInModifier) -> Self {
        n.syntax
    }
}
impl From<TsInModifier> for SyntaxElement {
    fn from(n: TsInModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsIndexSignatureClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INDEX_SIGNATURE_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INDEX_SIGNATURE_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsIndexSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsIndexSignatureClassMember")
                .field("modifiers", &self.modifiers())
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("parameter", &support::DebugSyntaxResult(self.parameter()))
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .field(
                    "type_annotation",
                    &support::DebugSyntaxResult(self.type_annotation()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsIndexSignatureClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsIndexSignatureClassMember> for SyntaxNode {
    fn from(n: TsIndexSignatureClassMember) -> Self {
        n.syntax
    }
}
impl From<TsIndexSignatureClassMember> for SyntaxElement {
    fn from(n: TsIndexSignatureClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsIndexSignatureParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INDEX_SIGNATURE_PARAMETER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INDEX_SIGNATURE_PARAMETER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsIndexSignatureParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsIndexSignatureParameter")
                .field("binding", &support::DebugSyntaxResult(self.binding()))
                .field(
                    "type_annotation",
                    &support::DebugSyntaxResult(self.type_annotation()),
                )
                .finish()
        } else {
            f.debug_struct("TsIndexSignatureParameter").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsIndexSignatureParameter> for SyntaxNode {
    fn from(n: TsIndexSignatureParameter) -> Self {
        n.syntax
    }
}
impl From<TsIndexSignatureParameter> for SyntaxElement {
    fn from(n: TsIndexSignatureParameter) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsIndexSignatureTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INDEX_SIGNATURE_TYPE_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INDEX_SIGNATURE_TYPE_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsIndexSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsIndexSignatureTypeMember")
                .field(
                    "readonly_token",
                    &support::DebugOptionalElement(self.readonly_token()),
                )
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("parameter", &support::DebugSyntaxResult(self.parameter()))
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .field(
                    "type_annotation",
                    &support::DebugSyntaxResult(self.type_annotation()),
                )
                .field(
                    "separator_token",
                    &support::DebugOptionalElement(self.separator_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsIndexSignatureTypeMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsIndexSignatureTypeMember> for SyntaxNode {
    fn from(n: TsIndexSignatureTypeMember) -> Self {
        n.syntax
    }
}
impl From<TsIndexSignatureTypeMember> for SyntaxElement {
    fn from(n: TsIndexSignatureTypeMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsIndexedAccessType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INDEXED_ACCESS_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INDEXED_ACCESS_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsIndexedAccessType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsIndexedAccessType")
                .field(
                    "object_type",
                    &support::DebugSyntaxResult(self.object_type()),
                )
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("index_type", &support::DebugSyntaxResult(self.index_type()))
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsIndexedAccessType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsIndexedAccessType> for SyntaxNode {
    fn from(n: TsIndexedAccessType) -> Self {
        n.syntax
    }
}
impl From<TsIndexedAccessType> for SyntaxElement {
    fn from(n: TsIndexedAccessType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsInferType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INFER_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INFER_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsInferType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsInferType")
                .field(
                    "infer_token",
                    &support::DebugSyntaxResult(self.infer_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "constraint",
                    &support::DebugOptionalElement(self.constraint()),
                )
                .finish()
        } else {
            f.debug_struct("TsInferType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsInferType> for SyntaxNode {
    fn from(n: TsInferType) -> Self {
        n.syntax
    }
}
impl From<TsInferType> for SyntaxElement {
    fn from(n: TsInferType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsInitializedPropertySignatureClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        TS_INITIALIZED_PROPERTY_SIGNATURE_CLASS_MEMBER as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INITIALIZED_PROPERTY_SIGNATURE_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsInitializedPropertySignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsInitializedPropertySignatureClassMember")
                .field("modifiers", &self.modifiers())
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "question_mark_token",
                    &support::DebugOptionalElement(self.question_mark_token()),
                )
                .field("value", &support::DebugSyntaxResult(self.value()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsInitializedPropertySignatureClassMember")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsInitializedPropertySignatureClassMember> for SyntaxNode {
    fn from(n: TsInitializedPropertySignatureClassMember) -> Self {
        n.syntax
    }
}
impl From<TsInitializedPropertySignatureClassMember> for SyntaxElement {
    fn from(n: TsInitializedPropertySignatureClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsInstantiationExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INSTANTIATION_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INSTANTIATION_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsInstantiationExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsInstantiationExpression")
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field("arguments", &support::DebugSyntaxResult(self.arguments()))
                .finish()
        } else {
            f.debug_struct("TsInstantiationExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsInstantiationExpression> for SyntaxNode {
    fn from(n: TsInstantiationExpression) -> Self {
        n.syntax
    }
}
impl From<TsInstantiationExpression> for SyntaxElement {
    fn from(n: TsInstantiationExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsInterfaceDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INTERFACE_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INTERFACE_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsInterfaceDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsInterfaceDeclaration")
                .field(
                    "interface_token",
                    &support::DebugSyntaxResult(self.interface_token()),
                )
                .field("id", &support::DebugSyntaxResult(self.id()))
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field(
                    "extends_clause",
                    &support::DebugOptionalElement(self.extends_clause()),
                )
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("members", &self.members())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsInterfaceDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsInterfaceDeclaration> for SyntaxNode {
    fn from(n: TsInterfaceDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsInterfaceDeclaration> for SyntaxElement {
    fn from(n: TsInterfaceDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsIntersectionType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INTERSECTION_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INTERSECTION_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsIntersectionType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsIntersectionType")
                .field(
                    "leading_separator_token",
                    &support::DebugOptionalElement(self.leading_separator_token()),
                )
                .field("types", &self.types())
                .finish()
        } else {
            f.debug_struct("TsIntersectionType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsIntersectionType> for SyntaxNode {
    fn from(n: TsIntersectionType) -> Self {
        n.syntax
    }
}
impl From<TsIntersectionType> for SyntaxElement {
    fn from(n: TsIntersectionType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsLiteralEnumMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_LITERAL_ENUM_MEMBER_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_LITERAL_ENUM_MEMBER_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsLiteralEnumMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsLiteralEnumMemberName")
                .field("value", &support::DebugSyntaxResult(self.value()))
                .finish()
        } else {
            f.debug_struct("TsLiteralEnumMemberName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsLiteralEnumMemberName> for SyntaxNode {
    fn from(n: TsLiteralEnumMemberName) -> Self {
        n.syntax
    }
}
impl From<TsLiteralEnumMemberName> for SyntaxElement {
    fn from(n: TsLiteralEnumMemberName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsMappedType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_MAPPED_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_MAPPED_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsMappedType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsMappedType")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field(
                    "readonly_modifier",
                    &support::DebugOptionalElement(self.readonly_modifier()),
                )
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field(
                    "property_name",
                    &support::DebugSyntaxResult(self.property_name()),
                )
                .field("in_token", &support::DebugSyntaxResult(self.in_token()))
                .field("keys_type", &support::DebugSyntaxResult(self.keys_type()))
                .field(
                    "as_clause",
                    &support::DebugOptionalElement(self.as_clause()),
                )
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .field(
                    "optional_modifier",
                    &support::DebugOptionalElement(self.optional_modifier()),
                )
                .field(
                    "mapped_type",
                    &support::DebugOptionalElement(self.mapped_type()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsMappedType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsMappedType> for SyntaxNode {
    fn from(n: TsMappedType) -> Self {
        n.syntax
    }
}
impl From<TsMappedType> for SyntaxElement {
    fn from(n: TsMappedType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsMappedTypeAsClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_MAPPED_TYPE_AS_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_MAPPED_TYPE_AS_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsMappedTypeAsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsMappedTypeAsClause")
                .field("as_token", &support::DebugSyntaxResult(self.as_token()))
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsMappedTypeAsClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsMappedTypeAsClause> for SyntaxNode {
    fn from(n: TsMappedTypeAsClause) -> Self {
        n.syntax
    }
}
impl From<TsMappedTypeAsClause> for SyntaxElement {
    fn from(n: TsMappedTypeAsClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsMappedTypeOptionalModifierClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        TS_MAPPED_TYPE_OPTIONAL_MODIFIER_CLAUSE as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_MAPPED_TYPE_OPTIONAL_MODIFIER_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsMappedTypeOptionalModifierClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsMappedTypeOptionalModifierClause")
                .field(
                    "operator_token",
                    &support::DebugOptionalElement(self.operator_token()),
                )
                .field(
                    "question_mark_token",
                    &support::DebugSyntaxResult(self.question_mark_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsMappedTypeOptionalModifierClause")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsMappedTypeOptionalModifierClause> for SyntaxNode {
    fn from(n: TsMappedTypeOptionalModifierClause) -> Self {
        n.syntax
    }
}
impl From<TsMappedTypeOptionalModifierClause> for SyntaxElement {
    fn from(n: TsMappedTypeOptionalModifierClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsMappedTypeReadonlyModifierClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        TS_MAPPED_TYPE_READONLY_MODIFIER_CLAUSE as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_MAPPED_TYPE_READONLY_MODIFIER_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsMappedTypeReadonlyModifierClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsMappedTypeReadonlyModifierClause")
                .field(
                    "operator_token",
                    &support::DebugOptionalElement(self.operator_token()),
                )
                .field(
                    "readonly_token",
                    &support::DebugSyntaxResult(self.readonly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsMappedTypeReadonlyModifierClause")
                .finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsMappedTypeReadonlyModifierClause> for SyntaxNode {
    fn from(n: TsMappedTypeReadonlyModifierClause) -> Self {
        n.syntax
    }
}
impl From<TsMappedTypeReadonlyModifierClause> for SyntaxElement {
    fn from(n: TsMappedTypeReadonlyModifierClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsMethodSignatureClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_METHOD_SIGNATURE_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_METHOD_SIGNATURE_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsMethodSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsMethodSignatureClassMember")
                .field("modifiers", &self.modifiers())
                .field(
                    "async_token",
                    &support::DebugOptionalElement(self.async_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "question_mark_token",
                    &support::DebugOptionalElement(self.question_mark_token()),
                )
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsMethodSignatureClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsMethodSignatureClassMember> for SyntaxNode {
    fn from(n: TsMethodSignatureClassMember) -> Self {
        n.syntax
    }
}
impl From<TsMethodSignatureClassMember> for SyntaxElement {
    fn from(n: TsMethodSignatureClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsMethodSignatureTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_METHOD_SIGNATURE_TYPE_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_METHOD_SIGNATURE_TYPE_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsMethodSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsMethodSignatureTypeMember")
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "optional_token",
                    &support::DebugOptionalElement(self.optional_token()),
                )
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("parameters", &support::DebugSyntaxResult(self.parameters()))
                .field(
                    "return_type_annotation",
                    &support::DebugOptionalElement(self.return_type_annotation()),
                )
                .field(
                    "separator_token",
                    &support::DebugOptionalElement(self.separator_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsMethodSignatureTypeMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsMethodSignatureTypeMember> for SyntaxNode {
    fn from(n: TsMethodSignatureTypeMember) -> Self {
        n.syntax
    }
}
impl From<TsMethodSignatureTypeMember> for SyntaxElement {
    fn from(n: TsMethodSignatureTypeMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsModuleBlock {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_MODULE_BLOCK as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_MODULE_BLOCK
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsModuleBlock {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsModuleBlock")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("items", &self.items())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsModuleBlock").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsModuleBlock> for SyntaxNode {
    fn from(n: TsModuleBlock) -> Self {
        n.syntax
    }
}
impl From<TsModuleBlock> for SyntaxElement {
    fn from(n: TsModuleBlock) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsModuleDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_MODULE_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_MODULE_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsModuleDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsModuleDeclaration")
                .field(
                    "module_or_namespace",
                    &support::DebugSyntaxResult(self.module_or_namespace()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field("body", &support::DebugSyntaxResult(self.body()))
                .finish()
        } else {
            f.debug_struct("TsModuleDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsModuleDeclaration> for SyntaxNode {
    fn from(n: TsModuleDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsModuleDeclaration> for SyntaxElement {
    fn from(n: TsModuleDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNamedTupleTypeElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NAMED_TUPLE_TYPE_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NAMED_TUPLE_TYPE_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNamedTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNamedTupleTypeElement")
                .field(
                    "dotdotdot_token",
                    &support::DebugOptionalElement(self.dotdotdot_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "question_mark_token",
                    &support::DebugOptionalElement(self.question_mark_token()),
                )
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsNamedTupleTypeElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNamedTupleTypeElement> for SyntaxNode {
    fn from(n: TsNamedTupleTypeElement) -> Self {
        n.syntax
    }
}
impl From<TsNamedTupleTypeElement> for SyntaxElement {
    fn from(n: TsNamedTupleTypeElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNeverType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NEVER_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NEVER_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNeverType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNeverType")
                .field(
                    "never_token",
                    &support::DebugSyntaxResult(self.never_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsNeverType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNeverType> for SyntaxNode {
    fn from(n: TsNeverType) -> Self {
        n.syntax
    }
}
impl From<TsNeverType> for SyntaxElement {
    fn from(n: TsNeverType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNonNullAssertionAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NON_NULL_ASSERTION_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NON_NULL_ASSERTION_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNonNullAssertionAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNonNullAssertionAssignment")
                .field("assignment", &support::DebugSyntaxResult(self.assignment()))
                .field("excl_token", &support::DebugSyntaxResult(self.excl_token()))
                .finish()
        } else {
            f.debug_struct("TsNonNullAssertionAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNonNullAssertionAssignment> for SyntaxNode {
    fn from(n: TsNonNullAssertionAssignment) -> Self {
        n.syntax
    }
}
impl From<TsNonNullAssertionAssignment> for SyntaxElement {
    fn from(n: TsNonNullAssertionAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNonNullAssertionExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NON_NULL_ASSERTION_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NON_NULL_ASSERTION_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNonNullAssertionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNonNullAssertionExpression")
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field("excl_token", &support::DebugSyntaxResult(self.excl_token()))
                .finish()
        } else {
            f.debug_struct("TsNonNullAssertionExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNonNullAssertionExpression> for SyntaxNode {
    fn from(n: TsNonNullAssertionExpression) -> Self {
        n.syntax
    }
}
impl From<TsNonNullAssertionExpression> for SyntaxElement {
    fn from(n: TsNonNullAssertionExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNonPrimitiveType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NON_PRIMITIVE_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NON_PRIMITIVE_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNonPrimitiveType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNonPrimitiveType")
                .field(
                    "object_token",
                    &support::DebugSyntaxResult(self.object_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsNonPrimitiveType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNonPrimitiveType> for SyntaxNode {
    fn from(n: TsNonPrimitiveType) -> Self {
        n.syntax
    }
}
impl From<TsNonPrimitiveType> for SyntaxElement {
    fn from(n: TsNonPrimitiveType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNullLiteralType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NULL_LITERAL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NULL_LITERAL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNullLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNullLiteralType")
                .field(
                    "literal_token",
                    &support::DebugSyntaxResult(self.literal_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsNullLiteralType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNullLiteralType> for SyntaxNode {
    fn from(n: TsNullLiteralType) -> Self {
        n.syntax
    }
}
impl From<TsNullLiteralType> for SyntaxElement {
    fn from(n: TsNullLiteralType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNumberLiteralType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NUMBER_LITERAL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NUMBER_LITERAL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNumberLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNumberLiteralType")
                .field(
                    "minus_token",
                    &support::DebugOptionalElement(self.minus_token()),
                )
                .field(
                    "literal_token",
                    &support::DebugSyntaxResult(self.literal_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsNumberLiteralType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNumberLiteralType> for SyntaxNode {
    fn from(n: TsNumberLiteralType) -> Self {
        n.syntax
    }
}
impl From<TsNumberLiteralType> for SyntaxElement {
    fn from(n: TsNumberLiteralType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsNumberType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_NUMBER_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_NUMBER_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsNumberType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsNumberType")
                .field(
                    "number_token",
                    &support::DebugSyntaxResult(self.number_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsNumberType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsNumberType> for SyntaxNode {
    fn from(n: TsNumberType) -> Self {
        n.syntax
    }
}
impl From<TsNumberType> for SyntaxElement {
    fn from(n: TsNumberType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsObjectType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_OBJECT_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_OBJECT_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsObjectType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsObjectType")
                .field(
                    "l_curly_token",
                    &support::DebugSyntaxResult(self.l_curly_token()),
                )
                .field("members", &self.members())
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsObjectType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsObjectType> for SyntaxNode {
    fn from(n: TsObjectType) -> Self {
        n.syntax
    }
}
impl From<TsObjectType> for SyntaxElement {
    fn from(n: TsObjectType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsOptionalPropertyAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_OPTIONAL_PROPERTY_ANNOTATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_OPTIONAL_PROPERTY_ANNOTATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsOptionalPropertyAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsOptionalPropertyAnnotation")
                .field(
                    "question_mark_token",
                    &support::DebugSyntaxResult(self.question_mark_token()),
                )
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .finish()
        } else {
            f.debug_struct("TsOptionalPropertyAnnotation").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsOptionalPropertyAnnotation> for SyntaxNode {
    fn from(n: TsOptionalPropertyAnnotation) -> Self {
        n.syntax
    }
}
impl From<TsOptionalPropertyAnnotation> for SyntaxElement {
    fn from(n: TsOptionalPropertyAnnotation) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsOptionalTupleTypeElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_OPTIONAL_TUPLE_TYPE_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_OPTIONAL_TUPLE_TYPE_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsOptionalTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsOptionalTupleTypeElement")
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .field(
                    "question_mark_token",
                    &support::DebugSyntaxResult(self.question_mark_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsOptionalTupleTypeElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsOptionalTupleTypeElement> for SyntaxNode {
    fn from(n: TsOptionalTupleTypeElement) -> Self {
        n.syntax
    }
}
impl From<TsOptionalTupleTypeElement> for SyntaxElement {
    fn from(n: TsOptionalTupleTypeElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsOutModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_OUT_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_OUT_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsOutModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsOutModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsOutModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsOutModifier> for SyntaxNode {
    fn from(n: TsOutModifier) -> Self {
        n.syntax
    }
}
impl From<TsOutModifier> for SyntaxElement {
    fn from(n: TsOutModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsOverrideModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_OVERRIDE_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_OVERRIDE_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsOverrideModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsOverrideModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsOverrideModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsOverrideModifier> for SyntaxNode {
    fn from(n: TsOverrideModifier) -> Self {
        n.syntax
    }
}
impl From<TsOverrideModifier> for SyntaxElement {
    fn from(n: TsOverrideModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsParenthesizedType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_PARENTHESIZED_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_PARENTHESIZED_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsParenthesizedType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsParenthesizedType")
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsParenthesizedType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsParenthesizedType> for SyntaxNode {
    fn from(n: TsParenthesizedType) -> Self {
        n.syntax
    }
}
impl From<TsParenthesizedType> for SyntaxElement {
    fn from(n: TsParenthesizedType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsPredicateReturnType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_PREDICATE_RETURN_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_PREDICATE_RETURN_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsPredicateReturnType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsPredicateReturnType")
                .field(
                    "parameter_name",
                    &support::DebugSyntaxResult(self.parameter_name()),
                )
                .field("is_token", &support::DebugSyntaxResult(self.is_token()))
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsPredicateReturnType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsPredicateReturnType> for SyntaxNode {
    fn from(n: TsPredicateReturnType) -> Self {
        n.syntax
    }
}
impl From<TsPredicateReturnType> for SyntaxElement {
    fn from(n: TsPredicateReturnType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsPropertyParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_PROPERTY_PARAMETER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_PROPERTY_PARAMETER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsPropertyParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsPropertyParameter")
                .field("decorators", &self.decorators())
                .field("modifiers", &self.modifiers())
                .field(
                    "formal_parameter",
                    &support::DebugSyntaxResult(self.formal_parameter()),
                )
                .finish()
        } else {
            f.debug_struct("TsPropertyParameter").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsPropertyParameter> for SyntaxNode {
    fn from(n: TsPropertyParameter) -> Self {
        n.syntax
    }
}
impl From<TsPropertyParameter> for SyntaxElement {
    fn from(n: TsPropertyParameter) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsPropertySignatureClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_PROPERTY_SIGNATURE_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_PROPERTY_SIGNATURE_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsPropertySignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsPropertySignatureClassMember")
                .field("modifiers", &self.modifiers())
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "property_annotation",
                    &support::DebugOptionalElement(self.property_annotation()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsPropertySignatureClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsPropertySignatureClassMember> for SyntaxNode {
    fn from(n: TsPropertySignatureClassMember) -> Self {
        n.syntax
    }
}
impl From<TsPropertySignatureClassMember> for SyntaxElement {
    fn from(n: TsPropertySignatureClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsPropertySignatureTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_PROPERTY_SIGNATURE_TYPE_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_PROPERTY_SIGNATURE_TYPE_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsPropertySignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsPropertySignatureTypeMember")
                .field(
                    "readonly_token",
                    &support::DebugOptionalElement(self.readonly_token()),
                )
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "optional_token",
                    &support::DebugOptionalElement(self.optional_token()),
                )
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .field(
                    "separator_token",
                    &support::DebugOptionalElement(self.separator_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsPropertySignatureTypeMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsPropertySignatureTypeMember> for SyntaxNode {
    fn from(n: TsPropertySignatureTypeMember) -> Self {
        n.syntax
    }
}
impl From<TsPropertySignatureTypeMember> for SyntaxElement {
    fn from(n: TsPropertySignatureTypeMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsQualifiedModuleName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_QUALIFIED_MODULE_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_QUALIFIED_MODULE_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsQualifiedModuleName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsQualifiedModuleName")
                .field("left", &support::DebugSyntaxResult(self.left()))
                .field("dot_token", &support::DebugSyntaxResult(self.dot_token()))
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("TsQualifiedModuleName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsQualifiedModuleName> for SyntaxNode {
    fn from(n: TsQualifiedModuleName) -> Self {
        n.syntax
    }
}
impl From<TsQualifiedModuleName> for SyntaxElement {
    fn from(n: TsQualifiedModuleName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsQualifiedName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_QUALIFIED_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_QUALIFIED_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsQualifiedName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsQualifiedName")
                .field("left", &support::DebugSyntaxResult(self.left()))
                .field("dot_token", &support::DebugSyntaxResult(self.dot_token()))
                .field("right", &support::DebugSyntaxResult(self.right()))
                .finish()
        } else {
            f.debug_struct("TsQualifiedName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsQualifiedName> for SyntaxNode {
    fn from(n: TsQualifiedName) -> Self {
        n.syntax
    }
}
impl From<TsQualifiedName> for SyntaxElement {
    fn from(n: TsQualifiedName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsReadonlyModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_READONLY_MODIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_READONLY_MODIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsReadonlyModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsReadonlyModifier")
                .field(
                    "modifier_token",
                    &support::DebugSyntaxResult(self.modifier_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsReadonlyModifier").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsReadonlyModifier> for SyntaxNode {
    fn from(n: TsReadonlyModifier) -> Self {
        n.syntax
    }
}
impl From<TsReadonlyModifier> for SyntaxElement {
    fn from(n: TsReadonlyModifier) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsReferenceType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_REFERENCE_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_REFERENCE_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsReferenceType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsReferenceType")
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .finish()
        } else {
            f.debug_struct("TsReferenceType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsReferenceType> for SyntaxNode {
    fn from(n: TsReferenceType) -> Self {
        n.syntax
    }
}
impl From<TsReferenceType> for SyntaxElement {
    fn from(n: TsReferenceType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsRestTupleTypeElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_REST_TUPLE_TYPE_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_REST_TUPLE_TYPE_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsRestTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsRestTupleTypeElement")
                .field(
                    "dotdotdot_token",
                    &support::DebugSyntaxResult(self.dotdotdot_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsRestTupleTypeElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsRestTupleTypeElement> for SyntaxNode {
    fn from(n: TsRestTupleTypeElement) -> Self {
        n.syntax
    }
}
impl From<TsRestTupleTypeElement> for SyntaxElement {
    fn from(n: TsRestTupleTypeElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsReturnTypeAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_RETURN_TYPE_ANNOTATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_RETURN_TYPE_ANNOTATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsReturnTypeAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsReturnTypeAnnotation")
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsReturnTypeAnnotation").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsReturnTypeAnnotation> for SyntaxNode {
    fn from(n: TsReturnTypeAnnotation) -> Self {
        n.syntax
    }
}
impl From<TsReturnTypeAnnotation> for SyntaxElement {
    fn from(n: TsReturnTypeAnnotation) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsSatisfiesAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_SATISFIES_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_SATISFIES_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsSatisfiesAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsSatisfiesAssignment")
                .field("assignment", &support::DebugSyntaxResult(self.assignment()))
                .field(
                    "satisfies_token",
                    &support::DebugSyntaxResult(self.satisfies_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsSatisfiesAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsSatisfiesAssignment> for SyntaxNode {
    fn from(n: TsSatisfiesAssignment) -> Self {
        n.syntax
    }
}
impl From<TsSatisfiesAssignment> for SyntaxElement {
    fn from(n: TsSatisfiesAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsSatisfiesExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_SATISFIES_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_SATISFIES_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsSatisfiesExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsSatisfiesExpression")
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .field(
                    "satisfies_token",
                    &support::DebugSyntaxResult(self.satisfies_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsSatisfiesExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsSatisfiesExpression> for SyntaxNode {
    fn from(n: TsSatisfiesExpression) -> Self {
        n.syntax
    }
}
impl From<TsSatisfiesExpression> for SyntaxElement {
    fn from(n: TsSatisfiesExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsSetterSignatureClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_SETTER_SIGNATURE_CLASS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_SETTER_SIGNATURE_CLASS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsSetterSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsSetterSignatureClassMember")
                .field("modifiers", &self.modifiers())
                .field("set_token", &support::DebugSyntaxResult(self.set_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("parameter", &support::DebugSyntaxResult(self.parameter()))
                .field(
                    "comma_token",
                    &support::DebugOptionalElement(self.comma_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsSetterSignatureClassMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsSetterSignatureClassMember> for SyntaxNode {
    fn from(n: TsSetterSignatureClassMember) -> Self {
        n.syntax
    }
}
impl From<TsSetterSignatureClassMember> for SyntaxElement {
    fn from(n: TsSetterSignatureClassMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsSetterSignatureTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_SETTER_SIGNATURE_TYPE_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_SETTER_SIGNATURE_TYPE_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsSetterSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsSetterSignatureTypeMember")
                .field("set_token", &support::DebugSyntaxResult(self.set_token()))
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "l_paren_token",
                    &support::DebugSyntaxResult(self.l_paren_token()),
                )
                .field("parameter", &support::DebugSyntaxResult(self.parameter()))
                .field(
                    "comma_token",
                    &support::DebugOptionalElement(self.comma_token()),
                )
                .field(
                    "r_paren_token",
                    &support::DebugSyntaxResult(self.r_paren_token()),
                )
                .field(
                    "separator_token",
                    &support::DebugOptionalElement(self.separator_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsSetterSignatureTypeMember").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsSetterSignatureTypeMember> for SyntaxNode {
    fn from(n: TsSetterSignatureTypeMember) -> Self {
        n.syntax
    }
}
impl From<TsSetterSignatureTypeMember> for SyntaxElement {
    fn from(n: TsSetterSignatureTypeMember) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsStringLiteralType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_STRING_LITERAL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_STRING_LITERAL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsStringLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsStringLiteralType")
                .field(
                    "literal_token",
                    &support::DebugSyntaxResult(self.literal_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsStringLiteralType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsStringLiteralType> for SyntaxNode {
    fn from(n: TsStringLiteralType) -> Self {
        n.syntax
    }
}
impl From<TsStringLiteralType> for SyntaxElement {
    fn from(n: TsStringLiteralType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsStringType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_STRING_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_STRING_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsStringType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsStringType")
                .field(
                    "string_token",
                    &support::DebugSyntaxResult(self.string_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsStringType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsStringType> for SyntaxNode {
    fn from(n: TsStringType) -> Self {
        n.syntax
    }
}
impl From<TsStringType> for SyntaxElement {
    fn from(n: TsStringType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsSymbolType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_SYMBOL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_SYMBOL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsSymbolType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsSymbolType")
                .field(
                    "symbol_token",
                    &support::DebugSyntaxResult(self.symbol_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsSymbolType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsSymbolType> for SyntaxNode {
    fn from(n: TsSymbolType) -> Self {
        n.syntax
    }
}
impl From<TsSymbolType> for SyntaxElement {
    fn from(n: TsSymbolType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTemplateChunkElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TEMPLATE_CHUNK_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TEMPLATE_CHUNK_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTemplateChunkElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTemplateChunkElement")
                .field(
                    "template_chunk_token",
                    &support::DebugSyntaxResult(self.template_chunk_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTemplateChunkElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTemplateChunkElement> for SyntaxNode {
    fn from(n: TsTemplateChunkElement) -> Self {
        n.syntax
    }
}
impl From<TsTemplateChunkElement> for SyntaxElement {
    fn from(n: TsTemplateChunkElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTemplateElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TEMPLATE_ELEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TEMPLATE_ELEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTemplateElement")
                .field(
                    "dollar_curly_token",
                    &support::DebugSyntaxResult(self.dollar_curly_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .field(
                    "r_curly_token",
                    &support::DebugSyntaxResult(self.r_curly_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTemplateElement").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTemplateElement> for SyntaxNode {
    fn from(n: TsTemplateElement) -> Self {
        n.syntax
    }
}
impl From<TsTemplateElement> for SyntaxElement {
    fn from(n: TsTemplateElement) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTemplateLiteralType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TEMPLATE_LITERAL_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TEMPLATE_LITERAL_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTemplateLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTemplateLiteralType")
                .field(
                    "l_tick_token",
                    &support::DebugSyntaxResult(self.l_tick_token()),
                )
                .field("elements", &self.elements())
                .field(
                    "r_tick_token",
                    &support::DebugSyntaxResult(self.r_tick_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTemplateLiteralType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTemplateLiteralType> for SyntaxNode {
    fn from(n: TsTemplateLiteralType) -> Self {
        n.syntax
    }
}
impl From<TsTemplateLiteralType> for SyntaxElement {
    fn from(n: TsTemplateLiteralType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsThisParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_THIS_PARAMETER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_THIS_PARAMETER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsThisParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsThisParameter")
                .field("this_token", &support::DebugSyntaxResult(self.this_token()))
                .field(
                    "type_annotation",
                    &support::DebugOptionalElement(self.type_annotation()),
                )
                .finish()
        } else {
            f.debug_struct("TsThisParameter").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsThisParameter> for SyntaxNode {
    fn from(n: TsThisParameter) -> Self {
        n.syntax
    }
}
impl From<TsThisParameter> for SyntaxElement {
    fn from(n: TsThisParameter) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsThisType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_THIS_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_THIS_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsThisType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsThisType")
                .field("this_token", &support::DebugSyntaxResult(self.this_token()))
                .finish()
        } else {
            f.debug_struct("TsThisType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsThisType> for SyntaxNode {
    fn from(n: TsThisType) -> Self {
        n.syntax
    }
}
impl From<TsThisType> for SyntaxElement {
    fn from(n: TsThisType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTupleType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TUPLE_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TUPLE_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTupleType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTupleType")
                .field(
                    "l_brack_token",
                    &support::DebugSyntaxResult(self.l_brack_token()),
                )
                .field("elements", &self.elements())
                .field(
                    "r_brack_token",
                    &support::DebugSyntaxResult(self.r_brack_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTupleType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTupleType> for SyntaxNode {
    fn from(n: TsTupleType) -> Self {
        n.syntax
    }
}
impl From<TsTupleType> for SyntaxElement {
    fn from(n: TsTupleType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeAliasDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_ALIAS_DECLARATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_ALIAS_DECLARATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeAliasDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeAliasDeclaration")
                .field("type_token", &support::DebugSyntaxResult(self.type_token()))
                .field(
                    "binding_identifier",
                    &support::DebugSyntaxResult(self.binding_identifier()),
                )
                .field(
                    "type_parameters",
                    &support::DebugOptionalElement(self.type_parameters()),
                )
                .field("eq_token", &support::DebugSyntaxResult(self.eq_token()))
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .field(
                    "semicolon_token",
                    &support::DebugOptionalElement(self.semicolon_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTypeAliasDeclaration").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeAliasDeclaration> for SyntaxNode {
    fn from(n: TsTypeAliasDeclaration) -> Self {
        n.syntax
    }
}
impl From<TsTypeAliasDeclaration> for SyntaxElement {
    fn from(n: TsTypeAliasDeclaration) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_ANNOTATION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_ANNOTATION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeAnnotation")
                .field(
                    "colon_token",
                    &support::DebugSyntaxResult(self.colon_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsTypeAnnotation").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeAnnotation> for SyntaxNode {
    fn from(n: TsTypeAnnotation) -> Self {
        n.syntax
    }
}
impl From<TsTypeAnnotation> for SyntaxElement {
    fn from(n: TsTypeAnnotation) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeArguments {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_ARGUMENTS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_ARGUMENTS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeArguments {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeArguments")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field("ts_type_argument_list", &self.ts_type_argument_list())
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTypeArguments").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeArguments> for SyntaxNode {
    fn from(n: TsTypeArguments) -> Self {
        n.syntax
    }
}
impl From<TsTypeArguments> for SyntaxElement {
    fn from(n: TsTypeArguments) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeAssertionAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_ASSERTION_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_ASSERTION_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeAssertionAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeAssertionAssignment")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .field("assignment", &support::DebugSyntaxResult(self.assignment()))
                .finish()
        } else {
            f.debug_struct("TsTypeAssertionAssignment").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeAssertionAssignment> for SyntaxNode {
    fn from(n: TsTypeAssertionAssignment) -> Self {
        n.syntax
    }
}
impl From<TsTypeAssertionAssignment> for SyntaxElement {
    fn from(n: TsTypeAssertionAssignment) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeAssertionExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_ASSERTION_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_ASSERTION_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeAssertionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeAssertionExpression")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .field("expression", &support::DebugSyntaxResult(self.expression()))
                .finish()
        } else {
            f.debug_struct("TsTypeAssertionExpression").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeAssertionExpression> for SyntaxNode {
    fn from(n: TsTypeAssertionExpression) -> Self {
        n.syntax
    }
}
impl From<TsTypeAssertionExpression> for SyntaxElement {
    fn from(n: TsTypeAssertionExpression) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeConstraintClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_CONSTRAINT_CLAUSE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_CONSTRAINT_CLAUSE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeConstraintClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeConstraintClause")
                .field(
                    "extends_token",
                    &support::DebugSyntaxResult(self.extends_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsTypeConstraintClause").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeConstraintClause> for SyntaxNode {
    fn from(n: TsTypeConstraintClause) -> Self {
        n.syntax
    }
}
impl From<TsTypeConstraintClause> for SyntaxElement {
    fn from(n: TsTypeConstraintClause) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeOperatorType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_OPERATOR_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_OPERATOR_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeOperatorType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeOperatorType")
                .field(
                    "operator_token",
                    &support::DebugSyntaxResult(self.operator_token()),
                )
                .field("ty", &support::DebugSyntaxResult(self.ty()))
                .finish()
        } else {
            f.debug_struct("TsTypeOperatorType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeOperatorType> for SyntaxNode {
    fn from(n: TsTypeOperatorType) -> Self {
        n.syntax
    }
}
impl From<TsTypeOperatorType> for SyntaxElement {
    fn from(n: TsTypeOperatorType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_PARAMETER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_PARAMETER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeParameter")
                .field("modifiers", &self.modifiers())
                .field("name", &support::DebugSyntaxResult(self.name()))
                .field(
                    "constraint",
                    &support::DebugOptionalElement(self.constraint()),
                )
                .field("default", &support::DebugOptionalElement(self.default()))
                .finish()
        } else {
            f.debug_struct("TsTypeParameter").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeParameter> for SyntaxNode {
    fn from(n: TsTypeParameter) -> Self {
        n.syntax
    }
}
impl From<TsTypeParameter> for SyntaxElement {
    fn from(n: TsTypeParameter) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeParameterName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_PARAMETER_NAME as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_PARAMETER_NAME
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeParameterName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeParameterName")
                .field(
                    "ident_token",
                    &support::DebugSyntaxResult(self.ident_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTypeParameterName").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeParameterName> for SyntaxNode {
    fn from(n: TsTypeParameterName) -> Self {
        n.syntax
    }
}
impl From<TsTypeParameterName> for SyntaxElement {
    fn from(n: TsTypeParameterName) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeParameters {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_PARAMETERS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_PARAMETERS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeParameters")
                .field(
                    "l_angle_token",
                    &support::DebugSyntaxResult(self.l_angle_token()),
                )
                .field("items", &self.items())
                .field(
                    "r_angle_token",
                    &support::DebugSyntaxResult(self.r_angle_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsTypeParameters").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeParameters> for SyntaxNode {
    fn from(n: TsTypeParameters) -> Self {
        n.syntax
    }
}
impl From<TsTypeParameters> for SyntaxElement {
    fn from(n: TsTypeParameters) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsTypeofType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPEOF_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPEOF_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsTypeofType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsTypeofType")
                .field(
                    "typeof_token",
                    &support::DebugSyntaxResult(self.typeof_token()),
                )
                .field(
                    "expression_name",
                    &support::DebugSyntaxResult(self.expression_name()),
                )
                .field(
                    "type_arguments",
                    &support::DebugOptionalElement(self.type_arguments()),
                )
                .finish()
        } else {
            f.debug_struct("TsTypeofType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsTypeofType> for SyntaxNode {
    fn from(n: TsTypeofType) -> Self {
        n.syntax
    }
}
impl From<TsTypeofType> for SyntaxElement {
    fn from(n: TsTypeofType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsUndefinedType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_UNDEFINED_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_UNDEFINED_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsUndefinedType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsUndefinedType")
                .field(
                    "undefined_token",
                    &support::DebugSyntaxResult(self.undefined_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsUndefinedType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsUndefinedType> for SyntaxNode {
    fn from(n: TsUndefinedType) -> Self {
        n.syntax
    }
}
impl From<TsUndefinedType> for SyntaxElement {
    fn from(n: TsUndefinedType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsUnionType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_UNION_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_UNION_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsUnionType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsUnionType")
                .field(
                    "leading_separator_token",
                    &support::DebugOptionalElement(self.leading_separator_token()),
                )
                .field("types", &self.types())
                .finish()
        } else {
            f.debug_struct("TsUnionType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsUnionType> for SyntaxNode {
    fn from(n: TsUnionType) -> Self {
        n.syntax
    }
}
impl From<TsUnionType> for SyntaxElement {
    fn from(n: TsUnionType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsUnknownType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_UNKNOWN_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_UNKNOWN_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsUnknownType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsUnknownType")
                .field(
                    "unknown_token",
                    &support::DebugSyntaxResult(self.unknown_token()),
                )
                .finish()
        } else {
            f.debug_struct("TsUnknownType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsUnknownType> for SyntaxNode {
    fn from(n: TsUnknownType) -> Self {
        n.syntax
    }
}
impl From<TsUnknownType> for SyntaxElement {
    fn from(n: TsUnknownType) -> Self {
        n.syntax.into()
    }
}
impl AstNode for TsVoidType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_VOID_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_VOID_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsVoidType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        thread_local! { static DEPTH : std :: cell :: Cell < u8 > = const { std :: cell :: Cell :: new (0) } };
        let current_depth = DEPTH.get();
        let result = if current_depth < 16 {
            DEPTH.set(current_depth + 1);
            f.debug_struct("TsVoidType")
                .field("void_token", &support::DebugSyntaxResult(self.void_token()))
                .finish()
        } else {
            f.debug_struct("TsVoidType").finish()
        };
        DEPTH.set(current_depth);
        result
    }
}
impl From<TsVoidType> for SyntaxNode {
    fn from(n: TsVoidType) -> Self {
        n.syntax
    }
}
impl From<TsVoidType> for SyntaxElement {
    fn from(n: TsVoidType) -> Self {
        n.syntax.into()
    }
}
impl From<JsArrayAssignmentPatternElement> for AnyJsArrayAssignmentPatternElement {
    fn from(node: JsArrayAssignmentPatternElement) -> Self {
        Self::JsArrayAssignmentPatternElement(node)
    }
}
impl From<JsArrayAssignmentPatternRestElement> for AnyJsArrayAssignmentPatternElement {
    fn from(node: JsArrayAssignmentPatternRestElement) -> Self {
        Self::JsArrayAssignmentPatternRestElement(node)
    }
}
impl From<JsArrayHole> for AnyJsArrayAssignmentPatternElement {
    fn from(node: JsArrayHole) -> Self {
        Self::JsArrayHole(node)
    }
}
impl AstNode for AnyJsArrayAssignmentPatternElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsArrayAssignmentPatternElement::KIND_SET
        .union(JsArrayAssignmentPatternRestElement::KIND_SET)
        .union(JsArrayHole::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_ARRAY_ASSIGNMENT_PATTERN_ELEMENT
                | JS_ARRAY_ASSIGNMENT_PATTERN_REST_ELEMENT
                | JS_ARRAY_HOLE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ARRAY_ASSIGNMENT_PATTERN_ELEMENT => {
                Self::JsArrayAssignmentPatternElement(JsArrayAssignmentPatternElement { syntax })
            }
            JS_ARRAY_ASSIGNMENT_PATTERN_REST_ELEMENT => {
                Self::JsArrayAssignmentPatternRestElement(JsArrayAssignmentPatternRestElement {
                    syntax,
                })
            }
            JS_ARRAY_HOLE => Self::JsArrayHole(JsArrayHole { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsArrayAssignmentPatternElement(it) => it.syntax(),
            Self::JsArrayAssignmentPatternRestElement(it) => it.syntax(),
            Self::JsArrayHole(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsArrayAssignmentPatternElement(it) => it.into_syntax(),
            Self::JsArrayAssignmentPatternRestElement(it) => it.into_syntax(),
            Self::JsArrayHole(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsArrayAssignmentPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsArrayAssignmentPatternElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayAssignmentPatternRestElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayHole(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsArrayAssignmentPatternElement> for SyntaxNode {
    fn from(n: AnyJsArrayAssignmentPatternElement) -> Self {
        match n {
            AnyJsArrayAssignmentPatternElement::JsArrayAssignmentPatternElement(it) => {
                it.into_syntax()
            }
            AnyJsArrayAssignmentPatternElement::JsArrayAssignmentPatternRestElement(it) => {
                it.into_syntax()
            }
            AnyJsArrayAssignmentPatternElement::JsArrayHole(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsArrayAssignmentPatternElement> for SyntaxElement {
    fn from(n: AnyJsArrayAssignmentPatternElement) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsArrayBindingPatternElement> for AnyJsArrayBindingPatternElement {
    fn from(node: JsArrayBindingPatternElement) -> Self {
        Self::JsArrayBindingPatternElement(node)
    }
}
impl From<JsArrayBindingPatternRestElement> for AnyJsArrayBindingPatternElement {
    fn from(node: JsArrayBindingPatternRestElement) -> Self {
        Self::JsArrayBindingPatternRestElement(node)
    }
}
impl From<JsArrayHole> for AnyJsArrayBindingPatternElement {
    fn from(node: JsArrayHole) -> Self {
        Self::JsArrayHole(node)
    }
}
impl AstNode for AnyJsArrayBindingPatternElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsArrayBindingPatternElement::KIND_SET
        .union(JsArrayBindingPatternRestElement::KIND_SET)
        .union(JsArrayHole::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_ARRAY_BINDING_PATTERN_ELEMENT
                | JS_ARRAY_BINDING_PATTERN_REST_ELEMENT
                | JS_ARRAY_HOLE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ARRAY_BINDING_PATTERN_ELEMENT => {
                Self::JsArrayBindingPatternElement(JsArrayBindingPatternElement { syntax })
            }
            JS_ARRAY_BINDING_PATTERN_REST_ELEMENT => {
                Self::JsArrayBindingPatternRestElement(JsArrayBindingPatternRestElement { syntax })
            }
            JS_ARRAY_HOLE => Self::JsArrayHole(JsArrayHole { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsArrayBindingPatternElement(it) => it.syntax(),
            Self::JsArrayBindingPatternRestElement(it) => it.syntax(),
            Self::JsArrayHole(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsArrayBindingPatternElement(it) => it.into_syntax(),
            Self::JsArrayBindingPatternRestElement(it) => it.into_syntax(),
            Self::JsArrayHole(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsArrayBindingPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsArrayBindingPatternElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayBindingPatternRestElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayHole(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsArrayBindingPatternElement> for SyntaxNode {
    fn from(n: AnyJsArrayBindingPatternElement) -> Self {
        match n {
            AnyJsArrayBindingPatternElement::JsArrayBindingPatternElement(it) => it.into_syntax(),
            AnyJsArrayBindingPatternElement::JsArrayBindingPatternRestElement(it) => {
                it.into_syntax()
            }
            AnyJsArrayBindingPatternElement::JsArrayHole(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsArrayBindingPatternElement> for SyntaxElement {
    fn from(n: AnyJsArrayBindingPatternElement) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsArrayHole> for AnyJsArrayElement {
    fn from(node: JsArrayHole) -> Self {
        Self::JsArrayHole(node)
    }
}
impl From<JsSpread> for AnyJsArrayElement {
    fn from(node: JsSpread) -> Self {
        Self::JsSpread(node)
    }
}
impl AstNode for AnyJsArrayElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsExpression::KIND_SET
        .union(JsArrayHole::KIND_SET)
        .union(JsSpread::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_ARRAY_HOLE | JS_SPREAD => true,
            k if AnyJsExpression::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ARRAY_HOLE => Self::JsArrayHole(JsArrayHole { syntax }),
            JS_SPREAD => Self::JsSpread(JsSpread { syntax }),
            _ => {
                if let Some(any_js_expression) = AnyJsExpression::cast(syntax) {
                    return Some(Self::AnyJsExpression(any_js_expression));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsArrayHole(it) => it.syntax(),
            Self::JsSpread(it) => it.syntax(),
            Self::AnyJsExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsArrayHole(it) => it.into_syntax(),
            Self::JsSpread(it) => it.into_syntax(),
            Self::AnyJsExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsArrayElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayHole(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSpread(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsArrayElement> for SyntaxNode {
    fn from(n: AnyJsArrayElement) -> Self {
        match n {
            AnyJsArrayElement::AnyJsExpression(it) => it.into_syntax(),
            AnyJsArrayElement::JsArrayHole(it) => it.into_syntax(),
            AnyJsArrayElement::JsSpread(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsArrayElement> for SyntaxElement {
    fn from(n: AnyJsArrayElement) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsParameters> for AnyJsArrowFunctionParameters {
    fn from(node: JsParameters) -> Self {
        Self::JsParameters(node)
    }
}
impl AstNode for AnyJsArrowFunctionParameters {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsBinding::KIND_SET.union(JsParameters::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_PARAMETERS => true,
            k if AnyJsBinding::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_PARAMETERS => Self::JsParameters(JsParameters { syntax }),
            _ => {
                if let Some(any_js_binding) = AnyJsBinding::cast(syntax) {
                    return Some(Self::AnyJsBinding(any_js_binding));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsParameters(it) => it.syntax(),
            Self::AnyJsBinding(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsParameters(it) => it.into_syntax(),
            Self::AnyJsBinding(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsArrowFunctionParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsBinding(it) => std::fmt::Debug::fmt(it, f),
            Self::JsParameters(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsArrowFunctionParameters> for SyntaxNode {
    fn from(n: AnyJsArrowFunctionParameters) -> Self {
        match n {
            AnyJsArrowFunctionParameters::AnyJsBinding(it) => it.into_syntax(),
            AnyJsArrowFunctionParameters::JsParameters(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsArrowFunctionParameters> for SyntaxElement {
    fn from(n: AnyJsArrowFunctionParameters) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusAssignment> for AnyJsAssignment {
    fn from(node: JsBogusAssignment) -> Self {
        Self::JsBogusAssignment(node)
    }
}
impl From<JsComputedMemberAssignment> for AnyJsAssignment {
    fn from(node: JsComputedMemberAssignment) -> Self {
        Self::JsComputedMemberAssignment(node)
    }
}
impl From<JsIdentifierAssignment> for AnyJsAssignment {
    fn from(node: JsIdentifierAssignment) -> Self {
        Self::JsIdentifierAssignment(node)
    }
}
impl From<JsParenthesizedAssignment> for AnyJsAssignment {
    fn from(node: JsParenthesizedAssignment) -> Self {
        Self::JsParenthesizedAssignment(node)
    }
}
impl From<JsStaticMemberAssignment> for AnyJsAssignment {
    fn from(node: JsStaticMemberAssignment) -> Self {
        Self::JsStaticMemberAssignment(node)
    }
}
impl From<TsAsAssignment> for AnyJsAssignment {
    fn from(node: TsAsAssignment) -> Self {
        Self::TsAsAssignment(node)
    }
}
impl From<TsNonNullAssertionAssignment> for AnyJsAssignment {
    fn from(node: TsNonNullAssertionAssignment) -> Self {
        Self::TsNonNullAssertionAssignment(node)
    }
}
impl From<TsSatisfiesAssignment> for AnyJsAssignment {
    fn from(node: TsSatisfiesAssignment) -> Self {
        Self::TsSatisfiesAssignment(node)
    }
}
impl From<TsTypeAssertionAssignment> for AnyJsAssignment {
    fn from(node: TsTypeAssertionAssignment) -> Self {
        Self::TsTypeAssertionAssignment(node)
    }
}
impl AstNode for AnyJsAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusAssignment::KIND_SET
        .union(JsComputedMemberAssignment::KIND_SET)
        .union(JsIdentifierAssignment::KIND_SET)
        .union(JsParenthesizedAssignment::KIND_SET)
        .union(JsStaticMemberAssignment::KIND_SET)
        .union(TsAsAssignment::KIND_SET)
        .union(TsNonNullAssertionAssignment::KIND_SET)
        .union(TsSatisfiesAssignment::KIND_SET)
        .union(TsTypeAssertionAssignment::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_ASSIGNMENT
                | JS_COMPUTED_MEMBER_ASSIGNMENT
                | JS_IDENTIFIER_ASSIGNMENT
                | JS_PARENTHESIZED_ASSIGNMENT
                | JS_STATIC_MEMBER_ASSIGNMENT
                | TS_AS_ASSIGNMENT
                | TS_NON_NULL_ASSERTION_ASSIGNMENT
                | TS_SATISFIES_ASSIGNMENT
                | TS_TYPE_ASSERTION_ASSIGNMENT
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_ASSIGNMENT => Self::JsBogusAssignment(JsBogusAssignment { syntax }),
            JS_COMPUTED_MEMBER_ASSIGNMENT => {
                Self::JsComputedMemberAssignment(JsComputedMemberAssignment { syntax })
            }
            JS_IDENTIFIER_ASSIGNMENT => {
                Self::JsIdentifierAssignment(JsIdentifierAssignment { syntax })
            }
            JS_PARENTHESIZED_ASSIGNMENT => {
                Self::JsParenthesizedAssignment(JsParenthesizedAssignment { syntax })
            }
            JS_STATIC_MEMBER_ASSIGNMENT => {
                Self::JsStaticMemberAssignment(JsStaticMemberAssignment { syntax })
            }
            TS_AS_ASSIGNMENT => Self::TsAsAssignment(TsAsAssignment { syntax }),
            TS_NON_NULL_ASSERTION_ASSIGNMENT => {
                Self::TsNonNullAssertionAssignment(TsNonNullAssertionAssignment { syntax })
            }
            TS_SATISFIES_ASSIGNMENT => {
                Self::TsSatisfiesAssignment(TsSatisfiesAssignment { syntax })
            }
            TS_TYPE_ASSERTION_ASSIGNMENT => {
                Self::TsTypeAssertionAssignment(TsTypeAssertionAssignment { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusAssignment(it) => it.syntax(),
            Self::JsComputedMemberAssignment(it) => it.syntax(),
            Self::JsIdentifierAssignment(it) => it.syntax(),
            Self::JsParenthesizedAssignment(it) => it.syntax(),
            Self::JsStaticMemberAssignment(it) => it.syntax(),
            Self::TsAsAssignment(it) => it.syntax(),
            Self::TsNonNullAssertionAssignment(it) => it.syntax(),
            Self::TsSatisfiesAssignment(it) => it.syntax(),
            Self::TsTypeAssertionAssignment(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusAssignment(it) => it.into_syntax(),
            Self::JsComputedMemberAssignment(it) => it.into_syntax(),
            Self::JsIdentifierAssignment(it) => it.into_syntax(),
            Self::JsParenthesizedAssignment(it) => it.into_syntax(),
            Self::JsStaticMemberAssignment(it) => it.into_syntax(),
            Self::TsAsAssignment(it) => it.into_syntax(),
            Self::TsNonNullAssertionAssignment(it) => it.into_syntax(),
            Self::TsSatisfiesAssignment(it) => it.into_syntax(),
            Self::TsTypeAssertionAssignment(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsComputedMemberAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsIdentifierAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsParenthesizedAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticMemberAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAsAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNonNullAssertionAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::TsSatisfiesAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAssertionAssignment(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsAssignment> for SyntaxNode {
    fn from(n: AnyJsAssignment) -> Self {
        match n {
            AnyJsAssignment::JsBogusAssignment(it) => it.into_syntax(),
            AnyJsAssignment::JsComputedMemberAssignment(it) => it.into_syntax(),
            AnyJsAssignment::JsIdentifierAssignment(it) => it.into_syntax(),
            AnyJsAssignment::JsParenthesizedAssignment(it) => it.into_syntax(),
            AnyJsAssignment::JsStaticMemberAssignment(it) => it.into_syntax(),
            AnyJsAssignment::TsAsAssignment(it) => it.into_syntax(),
            AnyJsAssignment::TsNonNullAssertionAssignment(it) => it.into_syntax(),
            AnyJsAssignment::TsSatisfiesAssignment(it) => it.into_syntax(),
            AnyJsAssignment::TsTypeAssertionAssignment(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsAssignment> for SyntaxElement {
    fn from(n: AnyJsAssignment) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsArrayAssignmentPattern> for AnyJsAssignmentPattern {
    fn from(node: JsArrayAssignmentPattern) -> Self {
        Self::JsArrayAssignmentPattern(node)
    }
}
impl From<JsObjectAssignmentPattern> for AnyJsAssignmentPattern {
    fn from(node: JsObjectAssignmentPattern) -> Self {
        Self::JsObjectAssignmentPattern(node)
    }
}
impl AstNode for AnyJsAssignmentPattern {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsAssignment::KIND_SET
        .union(JsArrayAssignmentPattern::KIND_SET)
        .union(JsObjectAssignmentPattern::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_ARRAY_ASSIGNMENT_PATTERN | JS_OBJECT_ASSIGNMENT_PATTERN => true,
            k if AnyJsAssignment::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ARRAY_ASSIGNMENT_PATTERN => {
                Self::JsArrayAssignmentPattern(JsArrayAssignmentPattern { syntax })
            }
            JS_OBJECT_ASSIGNMENT_PATTERN => {
                Self::JsObjectAssignmentPattern(JsObjectAssignmentPattern { syntax })
            }
            _ => {
                if let Some(any_js_assignment) = AnyJsAssignment::cast(syntax) {
                    return Some(Self::AnyJsAssignment(any_js_assignment));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsArrayAssignmentPattern(it) => it.syntax(),
            Self::JsObjectAssignmentPattern(it) => it.syntax(),
            Self::AnyJsAssignment(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsArrayAssignmentPattern(it) => it.into_syntax(),
            Self::JsObjectAssignmentPattern(it) => it.into_syntax(),
            Self::AnyJsAssignment(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsAssignmentPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayAssignmentPattern(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectAssignmentPattern(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsAssignmentPattern> for SyntaxNode {
    fn from(n: AnyJsAssignmentPattern) -> Self {
        match n {
            AnyJsAssignmentPattern::AnyJsAssignment(it) => it.into_syntax(),
            AnyJsAssignmentPattern::JsArrayAssignmentPattern(it) => it.into_syntax(),
            AnyJsAssignmentPattern::JsObjectAssignmentPattern(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsAssignmentPattern> for SyntaxElement {
    fn from(n: AnyJsAssignmentPattern) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusBinding> for AnyJsBinding {
    fn from(node: JsBogusBinding) -> Self {
        Self::JsBogusBinding(node)
    }
}
impl From<JsIdentifierBinding> for AnyJsBinding {
    fn from(node: JsIdentifierBinding) -> Self {
        Self::JsIdentifierBinding(node)
    }
}
impl From<JsMetavariable> for AnyJsBinding {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl AstNode for AnyJsBinding {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusBinding::KIND_SET
        .union(JsIdentifierBinding::KIND_SET)
        .union(JsMetavariable::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_BINDING | JS_IDENTIFIER_BINDING | JS_METAVARIABLE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_BINDING => Self::JsBogusBinding(JsBogusBinding { syntax }),
            JS_IDENTIFIER_BINDING => Self::JsIdentifierBinding(JsIdentifierBinding { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusBinding(it) => it.syntax(),
            Self::JsIdentifierBinding(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusBinding(it) => it.into_syntax(),
            Self::JsIdentifierBinding(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusBinding(it) => std::fmt::Debug::fmt(it, f),
            Self::JsIdentifierBinding(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsBinding> for SyntaxNode {
    fn from(n: AnyJsBinding) -> Self {
        match n {
            AnyJsBinding::JsBogusBinding(it) => it.into_syntax(),
            AnyJsBinding::JsIdentifierBinding(it) => it.into_syntax(),
            AnyJsBinding::JsMetavariable(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsBinding> for SyntaxElement {
    fn from(n: AnyJsBinding) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsArrayBindingPattern> for AnyJsBindingPattern {
    fn from(node: JsArrayBindingPattern) -> Self {
        Self::JsArrayBindingPattern(node)
    }
}
impl From<JsObjectBindingPattern> for AnyJsBindingPattern {
    fn from(node: JsObjectBindingPattern) -> Self {
        Self::JsObjectBindingPattern(node)
    }
}
impl AstNode for AnyJsBindingPattern {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsBinding::KIND_SET
        .union(JsArrayBindingPattern::KIND_SET)
        .union(JsObjectBindingPattern::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_ARRAY_BINDING_PATTERN | JS_OBJECT_BINDING_PATTERN => true,
            k if AnyJsBinding::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ARRAY_BINDING_PATTERN => {
                Self::JsArrayBindingPattern(JsArrayBindingPattern { syntax })
            }
            JS_OBJECT_BINDING_PATTERN => {
                Self::JsObjectBindingPattern(JsObjectBindingPattern { syntax })
            }
            _ => {
                if let Some(any_js_binding) = AnyJsBinding::cast(syntax) {
                    return Some(Self::AnyJsBinding(any_js_binding));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsArrayBindingPattern(it) => it.syntax(),
            Self::JsObjectBindingPattern(it) => it.syntax(),
            Self::AnyJsBinding(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsArrayBindingPattern(it) => it.into_syntax(),
            Self::JsObjectBindingPattern(it) => it.into_syntax(),
            Self::AnyJsBinding(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsBindingPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsBinding(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayBindingPattern(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectBindingPattern(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsBindingPattern> for SyntaxNode {
    fn from(n: AnyJsBindingPattern) -> Self {
        match n {
            AnyJsBindingPattern::AnyJsBinding(it) => it.into_syntax(),
            AnyJsBindingPattern::JsArrayBindingPattern(it) => it.into_syntax(),
            AnyJsBindingPattern::JsObjectBindingPattern(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsBindingPattern> for SyntaxElement {
    fn from(n: AnyJsBindingPattern) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsSpread> for AnyJsCallArgument {
    fn from(node: JsSpread) -> Self {
        Self::JsSpread(node)
    }
}
impl AstNode for AnyJsCallArgument {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsExpression::KIND_SET.union(JsSpread::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_SPREAD => true,
            k if AnyJsExpression::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_SPREAD => Self::JsSpread(JsSpread { syntax }),
            _ => {
                if let Some(any_js_expression) = AnyJsExpression::cast(syntax) {
                    return Some(Self::AnyJsExpression(any_js_expression));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsSpread(it) => it.syntax(),
            Self::AnyJsExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsSpread(it) => it.into_syntax(),
            Self::AnyJsExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsCallArgument {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSpread(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsCallArgument> for SyntaxNode {
    fn from(n: AnyJsCallArgument) -> Self {
        match n {
            AnyJsCallArgument::AnyJsExpression(it) => it.into_syntax(),
            AnyJsCallArgument::JsSpread(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsCallArgument> for SyntaxElement {
    fn from(n: AnyJsCallArgument) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsClassDeclaration> for AnyJsClass {
    fn from(node: JsClassDeclaration) -> Self {
        Self::JsClassDeclaration(node)
    }
}
impl From<JsClassExportDefaultDeclaration> for AnyJsClass {
    fn from(node: JsClassExportDefaultDeclaration) -> Self {
        Self::JsClassExportDefaultDeclaration(node)
    }
}
impl From<JsClassExpression> for AnyJsClass {
    fn from(node: JsClassExpression) -> Self {
        Self::JsClassExpression(node)
    }
}
impl AstNode for AnyJsClass {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsClassDeclaration::KIND_SET
        .union(JsClassExportDefaultDeclaration::KIND_SET)
        .union(JsClassExpression::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_CLASS_DECLARATION | JS_CLASS_EXPORT_DEFAULT_DECLARATION | JS_CLASS_EXPRESSION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_CLASS_DECLARATION => Self::JsClassDeclaration(JsClassDeclaration { syntax }),
            JS_CLASS_EXPORT_DEFAULT_DECLARATION => {
                Self::JsClassExportDefaultDeclaration(JsClassExportDefaultDeclaration { syntax })
            }
            JS_CLASS_EXPRESSION => Self::JsClassExpression(JsClassExpression { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsClassDeclaration(it) => it.syntax(),
            Self::JsClassExportDefaultDeclaration(it) => it.syntax(),
            Self::JsClassExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsClassDeclaration(it) => it.into_syntax(),
            Self::JsClassExportDefaultDeclaration(it) => it.into_syntax(),
            Self::JsClassExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsClass {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsClassDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsClassExportDefaultDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsClassExpression(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsClass> for SyntaxNode {
    fn from(n: AnyJsClass) -> Self {
        match n {
            AnyJsClass::JsClassDeclaration(it) => it.into_syntax(),
            AnyJsClass::JsClassExportDefaultDeclaration(it) => it.into_syntax(),
            AnyJsClass::JsClassExpression(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsClass> for SyntaxElement {
    fn from(n: AnyJsClass) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusMember> for AnyJsClassMember {
    fn from(node: JsBogusMember) -> Self {
        Self::JsBogusMember(node)
    }
}
impl From<JsConstructorClassMember> for AnyJsClassMember {
    fn from(node: JsConstructorClassMember) -> Self {
        Self::JsConstructorClassMember(node)
    }
}
impl From<JsEmptyClassMember> for AnyJsClassMember {
    fn from(node: JsEmptyClassMember) -> Self {
        Self::JsEmptyClassMember(node)
    }
}
impl From<JsGetterClassMember> for AnyJsClassMember {
    fn from(node: JsGetterClassMember) -> Self {
        Self::JsGetterClassMember(node)
    }
}
impl From<JsMetavariable> for AnyJsClassMember {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsMethodClassMember> for AnyJsClassMember {
    fn from(node: JsMethodClassMember) -> Self {
        Self::JsMethodClassMember(node)
    }
}
impl From<JsPropertyClassMember> for AnyJsClassMember {
    fn from(node: JsPropertyClassMember) -> Self {
        Self::JsPropertyClassMember(node)
    }
}
impl From<JsSetterClassMember> for AnyJsClassMember {
    fn from(node: JsSetterClassMember) -> Self {
        Self::JsSetterClassMember(node)
    }
}
impl From<JsStaticInitializationBlockClassMember> for AnyJsClassMember {
    fn from(node: JsStaticInitializationBlockClassMember) -> Self {
        Self::JsStaticInitializationBlockClassMember(node)
    }
}
impl From<TsConstructorSignatureClassMember> for AnyJsClassMember {
    fn from(node: TsConstructorSignatureClassMember) -> Self {
        Self::TsConstructorSignatureClassMember(node)
    }
}
impl From<TsGetterSignatureClassMember> for AnyJsClassMember {
    fn from(node: TsGetterSignatureClassMember) -> Self {
        Self::TsGetterSignatureClassMember(node)
    }
}
impl From<TsIndexSignatureClassMember> for AnyJsClassMember {
    fn from(node: TsIndexSignatureClassMember) -> Self {
        Self::TsIndexSignatureClassMember(node)
    }
}
impl From<TsInitializedPropertySignatureClassMember> for AnyJsClassMember {
    fn from(node: TsInitializedPropertySignatureClassMember) -> Self {
        Self::TsInitializedPropertySignatureClassMember(node)
    }
}
impl From<TsMethodSignatureClassMember> for AnyJsClassMember {
    fn from(node: TsMethodSignatureClassMember) -> Self {
        Self::TsMethodSignatureClassMember(node)
    }
}
impl From<TsPropertySignatureClassMember> for AnyJsClassMember {
    fn from(node: TsPropertySignatureClassMember) -> Self {
        Self::TsPropertySignatureClassMember(node)
    }
}
impl From<TsSetterSignatureClassMember> for AnyJsClassMember {
    fn from(node: TsSetterSignatureClassMember) -> Self {
        Self::TsSetterSignatureClassMember(node)
    }
}
impl AstNode for AnyJsClassMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusMember::KIND_SET
        .union(JsConstructorClassMember::KIND_SET)
        .union(JsEmptyClassMember::KIND_SET)
        .union(JsGetterClassMember::KIND_SET)
        .union(JsMetavariable::KIND_SET)
        .union(JsMethodClassMember::KIND_SET)
        .union(JsPropertyClassMember::KIND_SET)
        .union(JsSetterClassMember::KIND_SET)
        .union(JsStaticInitializationBlockClassMember::KIND_SET)
        .union(TsConstructorSignatureClassMember::KIND_SET)
        .union(TsGetterSignatureClassMember::KIND_SET)
        .union(TsIndexSignatureClassMember::KIND_SET)
        .union(TsInitializedPropertySignatureClassMember::KIND_SET)
        .union(TsMethodSignatureClassMember::KIND_SET)
        .union(TsPropertySignatureClassMember::KIND_SET)
        .union(TsSetterSignatureClassMember::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_MEMBER
                | JS_CONSTRUCTOR_CLASS_MEMBER
                | JS_EMPTY_CLASS_MEMBER
                | JS_GETTER_CLASS_MEMBER
                | JS_METAVARIABLE
                | JS_METHOD_CLASS_MEMBER
                | JS_PROPERTY_CLASS_MEMBER
                | JS_SETTER_CLASS_MEMBER
                | JS_STATIC_INITIALIZATION_BLOCK_CLASS_MEMBER
                | TS_CONSTRUCTOR_SIGNATURE_CLASS_MEMBER
                | TS_GETTER_SIGNATURE_CLASS_MEMBER
                | TS_INDEX_SIGNATURE_CLASS_MEMBER
                | TS_INITIALIZED_PROPERTY_SIGNATURE_CLASS_MEMBER
                | TS_METHOD_SIGNATURE_CLASS_MEMBER
                | TS_PROPERTY_SIGNATURE_CLASS_MEMBER
                | TS_SETTER_SIGNATURE_CLASS_MEMBER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_MEMBER => Self::JsBogusMember(JsBogusMember { syntax }),
            JS_CONSTRUCTOR_CLASS_MEMBER => {
                Self::JsConstructorClassMember(JsConstructorClassMember { syntax })
            }
            JS_EMPTY_CLASS_MEMBER => Self::JsEmptyClassMember(JsEmptyClassMember { syntax }),
            JS_GETTER_CLASS_MEMBER => Self::JsGetterClassMember(JsGetterClassMember { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_METHOD_CLASS_MEMBER => Self::JsMethodClassMember(JsMethodClassMember { syntax }),
            JS_PROPERTY_CLASS_MEMBER => {
                Self::JsPropertyClassMember(JsPropertyClassMember { syntax })
            }
            JS_SETTER_CLASS_MEMBER => Self::JsSetterClassMember(JsSetterClassMember { syntax }),
            JS_STATIC_INITIALIZATION_BLOCK_CLASS_MEMBER => {
                Self::JsStaticInitializationBlockClassMember(
                    JsStaticInitializationBlockClassMember { syntax },
                )
            }
            TS_CONSTRUCTOR_SIGNATURE_CLASS_MEMBER => {
                Self::TsConstructorSignatureClassMember(TsConstructorSignatureClassMember {
                    syntax,
                })
            }
            TS_GETTER_SIGNATURE_CLASS_MEMBER => {
                Self::TsGetterSignatureClassMember(TsGetterSignatureClassMember { syntax })
            }
            TS_INDEX_SIGNATURE_CLASS_MEMBER => {
                Self::TsIndexSignatureClassMember(TsIndexSignatureClassMember { syntax })
            }
            TS_INITIALIZED_PROPERTY_SIGNATURE_CLASS_MEMBER => {
                Self::TsInitializedPropertySignatureClassMember(
                    TsInitializedPropertySignatureClassMember { syntax },
                )
            }
            TS_METHOD_SIGNATURE_CLASS_MEMBER => {
                Self::TsMethodSignatureClassMember(TsMethodSignatureClassMember { syntax })
            }
            TS_PROPERTY_SIGNATURE_CLASS_MEMBER => {
                Self::TsPropertySignatureClassMember(TsPropertySignatureClassMember { syntax })
            }
            TS_SETTER_SIGNATURE_CLASS_MEMBER => {
                Self::TsSetterSignatureClassMember(TsSetterSignatureClassMember { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusMember(it) => it.syntax(),
            Self::JsConstructorClassMember(it) => it.syntax(),
            Self::JsEmptyClassMember(it) => it.syntax(),
            Self::JsGetterClassMember(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsMethodClassMember(it) => it.syntax(),
            Self::JsPropertyClassMember(it) => it.syntax(),
            Self::JsSetterClassMember(it) => it.syntax(),
            Self::JsStaticInitializationBlockClassMember(it) => it.syntax(),
            Self::TsConstructorSignatureClassMember(it) => it.syntax(),
            Self::TsGetterSignatureClassMember(it) => it.syntax(),
            Self::TsIndexSignatureClassMember(it) => it.syntax(),
            Self::TsInitializedPropertySignatureClassMember(it) => it.syntax(),
            Self::TsMethodSignatureClassMember(it) => it.syntax(),
            Self::TsPropertySignatureClassMember(it) => it.syntax(),
            Self::TsSetterSignatureClassMember(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusMember(it) => it.into_syntax(),
            Self::JsConstructorClassMember(it) => it.into_syntax(),
            Self::JsEmptyClassMember(it) => it.into_syntax(),
            Self::JsGetterClassMember(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsMethodClassMember(it) => it.into_syntax(),
            Self::JsPropertyClassMember(it) => it.into_syntax(),
            Self::JsSetterClassMember(it) => it.into_syntax(),
            Self::JsStaticInitializationBlockClassMember(it) => it.into_syntax(),
            Self::TsConstructorSignatureClassMember(it) => it.into_syntax(),
            Self::TsGetterSignatureClassMember(it) => it.into_syntax(),
            Self::TsIndexSignatureClassMember(it) => it.into_syntax(),
            Self::TsInitializedPropertySignatureClassMember(it) => it.into_syntax(),
            Self::TsMethodSignatureClassMember(it) => it.into_syntax(),
            Self::TsPropertySignatureClassMember(it) => it.into_syntax(),
            Self::TsSetterSignatureClassMember(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsConstructorClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsEmptyClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsGetterClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMethodClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsPropertyClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSetterClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticInitializationBlockClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsConstructorSignatureClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsGetterSignatureClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsIndexSignatureClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInitializedPropertySignatureClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsMethodSignatureClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsPropertySignatureClassMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsSetterSignatureClassMember(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsClassMember> for SyntaxNode {
    fn from(n: AnyJsClassMember) -> Self {
        match n {
            AnyJsClassMember::JsBogusMember(it) => it.into_syntax(),
            AnyJsClassMember::JsConstructorClassMember(it) => it.into_syntax(),
            AnyJsClassMember::JsEmptyClassMember(it) => it.into_syntax(),
            AnyJsClassMember::JsGetterClassMember(it) => it.into_syntax(),
            AnyJsClassMember::JsMetavariable(it) => it.into_syntax(),
            AnyJsClassMember::JsMethodClassMember(it) => it.into_syntax(),
            AnyJsClassMember::JsPropertyClassMember(it) => it.into_syntax(),
            AnyJsClassMember::JsSetterClassMember(it) => it.into_syntax(),
            AnyJsClassMember::JsStaticInitializationBlockClassMember(it) => it.into_syntax(),
            AnyJsClassMember::TsConstructorSignatureClassMember(it) => it.into_syntax(),
            AnyJsClassMember::TsGetterSignatureClassMember(it) => it.into_syntax(),
            AnyJsClassMember::TsIndexSignatureClassMember(it) => it.into_syntax(),
            AnyJsClassMember::TsInitializedPropertySignatureClassMember(it) => it.into_syntax(),
            AnyJsClassMember::TsMethodSignatureClassMember(it) => it.into_syntax(),
            AnyJsClassMember::TsPropertySignatureClassMember(it) => it.into_syntax(),
            AnyJsClassMember::TsSetterSignatureClassMember(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsClassMember> for SyntaxElement {
    fn from(n: AnyJsClassMember) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsComputedMemberName> for AnyJsClassMemberName {
    fn from(node: JsComputedMemberName) -> Self {
        Self::JsComputedMemberName(node)
    }
}
impl From<JsLiteralMemberName> for AnyJsClassMemberName {
    fn from(node: JsLiteralMemberName) -> Self {
        Self::JsLiteralMemberName(node)
    }
}
impl From<JsMetavariable> for AnyJsClassMemberName {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsPrivateClassMemberName> for AnyJsClassMemberName {
    fn from(node: JsPrivateClassMemberName) -> Self {
        Self::JsPrivateClassMemberName(node)
    }
}
impl AstNode for AnyJsClassMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsComputedMemberName::KIND_SET
        .union(JsLiteralMemberName::KIND_SET)
        .union(JsMetavariable::KIND_SET)
        .union(JsPrivateClassMemberName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_COMPUTED_MEMBER_NAME
                | JS_LITERAL_MEMBER_NAME
                | JS_METAVARIABLE
                | JS_PRIVATE_CLASS_MEMBER_NAME
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_COMPUTED_MEMBER_NAME => Self::JsComputedMemberName(JsComputedMemberName { syntax }),
            JS_LITERAL_MEMBER_NAME => Self::JsLiteralMemberName(JsLiteralMemberName { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_PRIVATE_CLASS_MEMBER_NAME => {
                Self::JsPrivateClassMemberName(JsPrivateClassMemberName { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsComputedMemberName(it) => it.syntax(),
            Self::JsLiteralMemberName(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsPrivateClassMemberName(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsComputedMemberName(it) => it.into_syntax(),
            Self::JsLiteralMemberName(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsPrivateClassMemberName(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsClassMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsComputedMemberName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsLiteralMemberName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsPrivateClassMemberName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsClassMemberName> for SyntaxNode {
    fn from(n: AnyJsClassMemberName) -> Self {
        match n {
            AnyJsClassMemberName::JsComputedMemberName(it) => it.into_syntax(),
            AnyJsClassMemberName::JsLiteralMemberName(it) => it.into_syntax(),
            AnyJsClassMemberName::JsMetavariable(it) => it.into_syntax(),
            AnyJsClassMemberName::JsPrivateClassMemberName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsClassMemberName> for SyntaxElement {
    fn from(n: AnyJsClassMemberName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsNamedImportSpecifiers> for AnyJsCombinedSpecifier {
    fn from(node: JsNamedImportSpecifiers) -> Self {
        Self::JsNamedImportSpecifiers(node)
    }
}
impl From<JsNamespaceImportSpecifier> for AnyJsCombinedSpecifier {
    fn from(node: JsNamespaceImportSpecifier) -> Self {
        Self::JsNamespaceImportSpecifier(node)
    }
}
impl AstNode for AnyJsCombinedSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsNamedImportSpecifiers::KIND_SET.union(JsNamespaceImportSpecifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_NAMED_IMPORT_SPECIFIERS | JS_NAMESPACE_IMPORT_SPECIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_NAMED_IMPORT_SPECIFIERS => {
                Self::JsNamedImportSpecifiers(JsNamedImportSpecifiers { syntax })
            }
            JS_NAMESPACE_IMPORT_SPECIFIER => {
                Self::JsNamespaceImportSpecifier(JsNamespaceImportSpecifier { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsNamedImportSpecifiers(it) => it.syntax(),
            Self::JsNamespaceImportSpecifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsNamedImportSpecifiers(it) => it.into_syntax(),
            Self::JsNamespaceImportSpecifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsCombinedSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsNamedImportSpecifiers(it) => std::fmt::Debug::fmt(it, f),
            Self::JsNamespaceImportSpecifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsCombinedSpecifier> for SyntaxNode {
    fn from(n: AnyJsCombinedSpecifier) -> Self {
        match n {
            AnyJsCombinedSpecifier::JsNamedImportSpecifiers(it) => it.into_syntax(),
            AnyJsCombinedSpecifier::JsNamespaceImportSpecifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsCombinedSpecifier> for SyntaxElement {
    fn from(n: AnyJsCombinedSpecifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsRestParameter> for AnyJsConstructorParameter {
    fn from(node: JsRestParameter) -> Self {
        Self::JsRestParameter(node)
    }
}
impl From<TsPropertyParameter> for AnyJsConstructorParameter {
    fn from(node: TsPropertyParameter) -> Self {
        Self::TsPropertyParameter(node)
    }
}
impl AstNode for AnyJsConstructorParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsFormalParameter::KIND_SET
        .union(JsRestParameter::KIND_SET)
        .union(TsPropertyParameter::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_REST_PARAMETER | TS_PROPERTY_PARAMETER => true,
            k if AnyJsFormalParameter::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_REST_PARAMETER => Self::JsRestParameter(JsRestParameter { syntax }),
            TS_PROPERTY_PARAMETER => Self::TsPropertyParameter(TsPropertyParameter { syntax }),
            _ => {
                if let Some(any_js_formal_parameter) = AnyJsFormalParameter::cast(syntax) {
                    return Some(Self::AnyJsFormalParameter(any_js_formal_parameter));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsRestParameter(it) => it.syntax(),
            Self::TsPropertyParameter(it) => it.syntax(),
            Self::AnyJsFormalParameter(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsRestParameter(it) => it.into_syntax(),
            Self::TsPropertyParameter(it) => it.into_syntax(),
            Self::AnyJsFormalParameter(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsConstructorParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsFormalParameter(it) => std::fmt::Debug::fmt(it, f),
            Self::JsRestParameter(it) => std::fmt::Debug::fmt(it, f),
            Self::TsPropertyParameter(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsConstructorParameter> for SyntaxNode {
    fn from(n: AnyJsConstructorParameter) -> Self {
        match n {
            AnyJsConstructorParameter::AnyJsFormalParameter(it) => it.into_syntax(),
            AnyJsConstructorParameter::JsRestParameter(it) => it.into_syntax(),
            AnyJsConstructorParameter::TsPropertyParameter(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsConstructorParameter> for SyntaxElement {
    fn from(n: AnyJsConstructorParameter) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsClassDeclaration> for AnyJsDeclaration {
    fn from(node: JsClassDeclaration) -> Self {
        Self::JsClassDeclaration(node)
    }
}
impl From<JsFunctionDeclaration> for AnyJsDeclaration {
    fn from(node: JsFunctionDeclaration) -> Self {
        Self::JsFunctionDeclaration(node)
    }
}
impl From<JsVariableDeclaration> for AnyJsDeclaration {
    fn from(node: JsVariableDeclaration) -> Self {
        Self::JsVariableDeclaration(node)
    }
}
impl From<TsDeclareFunctionDeclaration> for AnyJsDeclaration {
    fn from(node: TsDeclareFunctionDeclaration) -> Self {
        Self::TsDeclareFunctionDeclaration(node)
    }
}
impl From<TsEnumDeclaration> for AnyJsDeclaration {
    fn from(node: TsEnumDeclaration) -> Self {
        Self::TsEnumDeclaration(node)
    }
}
impl From<TsExternalModuleDeclaration> for AnyJsDeclaration {
    fn from(node: TsExternalModuleDeclaration) -> Self {
        Self::TsExternalModuleDeclaration(node)
    }
}
impl From<TsGlobalDeclaration> for AnyJsDeclaration {
    fn from(node: TsGlobalDeclaration) -> Self {
        Self::TsGlobalDeclaration(node)
    }
}
impl From<TsImportEqualsDeclaration> for AnyJsDeclaration {
    fn from(node: TsImportEqualsDeclaration) -> Self {
        Self::TsImportEqualsDeclaration(node)
    }
}
impl From<TsInterfaceDeclaration> for AnyJsDeclaration {
    fn from(node: TsInterfaceDeclaration) -> Self {
        Self::TsInterfaceDeclaration(node)
    }
}
impl From<TsModuleDeclaration> for AnyJsDeclaration {
    fn from(node: TsModuleDeclaration) -> Self {
        Self::TsModuleDeclaration(node)
    }
}
impl From<TsTypeAliasDeclaration> for AnyJsDeclaration {
    fn from(node: TsTypeAliasDeclaration) -> Self {
        Self::TsTypeAliasDeclaration(node)
    }
}
impl AstNode for AnyJsDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsClassDeclaration::KIND_SET
        .union(JsFunctionDeclaration::KIND_SET)
        .union(JsVariableDeclaration::KIND_SET)
        .union(TsDeclareFunctionDeclaration::KIND_SET)
        .union(TsEnumDeclaration::KIND_SET)
        .union(TsExternalModuleDeclaration::KIND_SET)
        .union(TsGlobalDeclaration::KIND_SET)
        .union(TsImportEqualsDeclaration::KIND_SET)
        .union(TsInterfaceDeclaration::KIND_SET)
        .union(TsModuleDeclaration::KIND_SET)
        .union(TsTypeAliasDeclaration::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_CLASS_DECLARATION
                | JS_FUNCTION_DECLARATION
                | JS_VARIABLE_DECLARATION
                | TS_DECLARE_FUNCTION_DECLARATION
                | TS_ENUM_DECLARATION
                | TS_EXTERNAL_MODULE_DECLARATION
                | TS_GLOBAL_DECLARATION
                | TS_IMPORT_EQUALS_DECLARATION
                | TS_INTERFACE_DECLARATION
                | TS_MODULE_DECLARATION
                | TS_TYPE_ALIAS_DECLARATION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_CLASS_DECLARATION => Self::JsClassDeclaration(JsClassDeclaration { syntax }),
            JS_FUNCTION_DECLARATION => {
                Self::JsFunctionDeclaration(JsFunctionDeclaration { syntax })
            }
            JS_VARIABLE_DECLARATION => {
                Self::JsVariableDeclaration(JsVariableDeclaration { syntax })
            }
            TS_DECLARE_FUNCTION_DECLARATION => {
                Self::TsDeclareFunctionDeclaration(TsDeclareFunctionDeclaration { syntax })
            }
            TS_ENUM_DECLARATION => Self::TsEnumDeclaration(TsEnumDeclaration { syntax }),
            TS_EXTERNAL_MODULE_DECLARATION => {
                Self::TsExternalModuleDeclaration(TsExternalModuleDeclaration { syntax })
            }
            TS_GLOBAL_DECLARATION => Self::TsGlobalDeclaration(TsGlobalDeclaration { syntax }),
            TS_IMPORT_EQUALS_DECLARATION => {
                Self::TsImportEqualsDeclaration(TsImportEqualsDeclaration { syntax })
            }
            TS_INTERFACE_DECLARATION => {
                Self::TsInterfaceDeclaration(TsInterfaceDeclaration { syntax })
            }
            TS_MODULE_DECLARATION => Self::TsModuleDeclaration(TsModuleDeclaration { syntax }),
            TS_TYPE_ALIAS_DECLARATION => {
                Self::TsTypeAliasDeclaration(TsTypeAliasDeclaration { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsClassDeclaration(it) => it.syntax(),
            Self::JsFunctionDeclaration(it) => it.syntax(),
            Self::JsVariableDeclaration(it) => it.syntax(),
            Self::TsDeclareFunctionDeclaration(it) => it.syntax(),
            Self::TsEnumDeclaration(it) => it.syntax(),
            Self::TsExternalModuleDeclaration(it) => it.syntax(),
            Self::TsGlobalDeclaration(it) => it.syntax(),
            Self::TsImportEqualsDeclaration(it) => it.syntax(),
            Self::TsInterfaceDeclaration(it) => it.syntax(),
            Self::TsModuleDeclaration(it) => it.syntax(),
            Self::TsTypeAliasDeclaration(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsClassDeclaration(it) => it.into_syntax(),
            Self::JsFunctionDeclaration(it) => it.into_syntax(),
            Self::JsVariableDeclaration(it) => it.into_syntax(),
            Self::TsDeclareFunctionDeclaration(it) => it.into_syntax(),
            Self::TsEnumDeclaration(it) => it.into_syntax(),
            Self::TsExternalModuleDeclaration(it) => it.into_syntax(),
            Self::TsGlobalDeclaration(it) => it.into_syntax(),
            Self::TsImportEqualsDeclaration(it) => it.into_syntax(),
            Self::TsInterfaceDeclaration(it) => it.into_syntax(),
            Self::TsModuleDeclaration(it) => it.into_syntax(),
            Self::TsTypeAliasDeclaration(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsClassDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsVariableDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsDeclareFunctionDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsEnumDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsExternalModuleDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsGlobalDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsImportEqualsDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInterfaceDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsModuleDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAliasDeclaration(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsDeclaration> for SyntaxNode {
    fn from(n: AnyJsDeclaration) -> Self {
        match n {
            AnyJsDeclaration::JsClassDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::JsFunctionDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::JsVariableDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsDeclareFunctionDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsEnumDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsExternalModuleDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsGlobalDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsImportEqualsDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsInterfaceDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsModuleDeclaration(it) => it.into_syntax(),
            AnyJsDeclaration::TsTypeAliasDeclaration(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsDeclaration> for SyntaxElement {
    fn from(n: AnyJsDeclaration) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsClassDeclaration> for AnyJsDeclarationClause {
    fn from(node: JsClassDeclaration) -> Self {
        Self::JsClassDeclaration(node)
    }
}
impl From<JsFunctionDeclaration> for AnyJsDeclarationClause {
    fn from(node: JsFunctionDeclaration) -> Self {
        Self::JsFunctionDeclaration(node)
    }
}
impl From<JsVariableDeclarationClause> for AnyJsDeclarationClause {
    fn from(node: JsVariableDeclarationClause) -> Self {
        Self::JsVariableDeclarationClause(node)
    }
}
impl From<TsDeclareFunctionDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsDeclareFunctionDeclaration) -> Self {
        Self::TsDeclareFunctionDeclaration(node)
    }
}
impl From<TsEnumDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsEnumDeclaration) -> Self {
        Self::TsEnumDeclaration(node)
    }
}
impl From<TsExternalModuleDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsExternalModuleDeclaration) -> Self {
        Self::TsExternalModuleDeclaration(node)
    }
}
impl From<TsGlobalDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsGlobalDeclaration) -> Self {
        Self::TsGlobalDeclaration(node)
    }
}
impl From<TsImportEqualsDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsImportEqualsDeclaration) -> Self {
        Self::TsImportEqualsDeclaration(node)
    }
}
impl From<TsInterfaceDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsInterfaceDeclaration) -> Self {
        Self::TsInterfaceDeclaration(node)
    }
}
impl From<TsModuleDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsModuleDeclaration) -> Self {
        Self::TsModuleDeclaration(node)
    }
}
impl From<TsTypeAliasDeclaration> for AnyJsDeclarationClause {
    fn from(node: TsTypeAliasDeclaration) -> Self {
        Self::TsTypeAliasDeclaration(node)
    }
}
impl AstNode for AnyJsDeclarationClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsClassDeclaration::KIND_SET
        .union(JsFunctionDeclaration::KIND_SET)
        .union(JsVariableDeclarationClause::KIND_SET)
        .union(TsDeclareFunctionDeclaration::KIND_SET)
        .union(TsEnumDeclaration::KIND_SET)
        .union(TsExternalModuleDeclaration::KIND_SET)
        .union(TsGlobalDeclaration::KIND_SET)
        .union(TsImportEqualsDeclaration::KIND_SET)
        .union(TsInterfaceDeclaration::KIND_SET)
        .union(TsModuleDeclaration::KIND_SET)
        .union(TsTypeAliasDeclaration::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_CLASS_DECLARATION
                | JS_FUNCTION_DECLARATION
                | JS_VARIABLE_DECLARATION_CLAUSE
                | TS_DECLARE_FUNCTION_DECLARATION
                | TS_ENUM_DECLARATION
                | TS_EXTERNAL_MODULE_DECLARATION
                | TS_GLOBAL_DECLARATION
                | TS_IMPORT_EQUALS_DECLARATION
                | TS_INTERFACE_DECLARATION
                | TS_MODULE_DECLARATION
                | TS_TYPE_ALIAS_DECLARATION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_CLASS_DECLARATION => Self::JsClassDeclaration(JsClassDeclaration { syntax }),
            JS_FUNCTION_DECLARATION => {
                Self::JsFunctionDeclaration(JsFunctionDeclaration { syntax })
            }
            JS_VARIABLE_DECLARATION_CLAUSE => {
                Self::JsVariableDeclarationClause(JsVariableDeclarationClause { syntax })
            }
            TS_DECLARE_FUNCTION_DECLARATION => {
                Self::TsDeclareFunctionDeclaration(TsDeclareFunctionDeclaration { syntax })
            }
            TS_ENUM_DECLARATION => Self::TsEnumDeclaration(TsEnumDeclaration { syntax }),
            TS_EXTERNAL_MODULE_DECLARATION => {
                Self::TsExternalModuleDeclaration(TsExternalModuleDeclaration { syntax })
            }
            TS_GLOBAL_DECLARATION => Self::TsGlobalDeclaration(TsGlobalDeclaration { syntax }),
            TS_IMPORT_EQUALS_DECLARATION => {
                Self::TsImportEqualsDeclaration(TsImportEqualsDeclaration { syntax })
            }
            TS_INTERFACE_DECLARATION => {
                Self::TsInterfaceDeclaration(TsInterfaceDeclaration { syntax })
            }
            TS_MODULE_DECLARATION => Self::TsModuleDeclaration(TsModuleDeclaration { syntax }),
            TS_TYPE_ALIAS_DECLARATION => {
                Self::TsTypeAliasDeclaration(TsTypeAliasDeclaration { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsClassDeclaration(it) => it.syntax(),
            Self::JsFunctionDeclaration(it) => it.syntax(),
            Self::JsVariableDeclarationClause(it) => it.syntax(),
            Self::TsDeclareFunctionDeclaration(it) => it.syntax(),
            Self::TsEnumDeclaration(it) => it.syntax(),
            Self::TsExternalModuleDeclaration(it) => it.syntax(),
            Self::TsGlobalDeclaration(it) => it.syntax(),
            Self::TsImportEqualsDeclaration(it) => it.syntax(),
            Self::TsInterfaceDeclaration(it) => it.syntax(),
            Self::TsModuleDeclaration(it) => it.syntax(),
            Self::TsTypeAliasDeclaration(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsClassDeclaration(it) => it.into_syntax(),
            Self::JsFunctionDeclaration(it) => it.into_syntax(),
            Self::JsVariableDeclarationClause(it) => it.into_syntax(),
            Self::TsDeclareFunctionDeclaration(it) => it.into_syntax(),
            Self::TsEnumDeclaration(it) => it.into_syntax(),
            Self::TsExternalModuleDeclaration(it) => it.into_syntax(),
            Self::TsGlobalDeclaration(it) => it.into_syntax(),
            Self::TsImportEqualsDeclaration(it) => it.into_syntax(),
            Self::TsInterfaceDeclaration(it) => it.into_syntax(),
            Self::TsModuleDeclaration(it) => it.into_syntax(),
            Self::TsTypeAliasDeclaration(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsDeclarationClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsClassDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsVariableDeclarationClause(it) => std::fmt::Debug::fmt(it, f),
            Self::TsDeclareFunctionDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsEnumDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsExternalModuleDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsGlobalDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsImportEqualsDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInterfaceDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsModuleDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAliasDeclaration(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsDeclarationClause> for SyntaxNode {
    fn from(n: AnyJsDeclarationClause) -> Self {
        match n {
            AnyJsDeclarationClause::JsClassDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::JsFunctionDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::JsVariableDeclarationClause(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsDeclareFunctionDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsEnumDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsExternalModuleDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsGlobalDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsImportEqualsDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsInterfaceDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsModuleDeclaration(it) => it.into_syntax(),
            AnyJsDeclarationClause::TsTypeAliasDeclaration(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsDeclarationClause> for SyntaxElement {
    fn from(n: AnyJsDeclarationClause) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusExpression> for AnyJsDecorator {
    fn from(node: JsBogusExpression) -> Self {
        Self::JsBogusExpression(node)
    }
}
impl From<JsCallExpression> for AnyJsDecorator {
    fn from(node: JsCallExpression) -> Self {
        Self::JsCallExpression(node)
    }
}
impl From<JsIdentifierExpression> for AnyJsDecorator {
    fn from(node: JsIdentifierExpression) -> Self {
        Self::JsIdentifierExpression(node)
    }
}
impl From<JsParenthesizedExpression> for AnyJsDecorator {
    fn from(node: JsParenthesizedExpression) -> Self {
        Self::JsParenthesizedExpression(node)
    }
}
impl From<JsStaticMemberExpression> for AnyJsDecorator {
    fn from(node: JsStaticMemberExpression) -> Self {
        Self::JsStaticMemberExpression(node)
    }
}
impl AstNode for AnyJsDecorator {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusExpression::KIND_SET
        .union(JsCallExpression::KIND_SET)
        .union(JsIdentifierExpression::KIND_SET)
        .union(JsParenthesizedExpression::KIND_SET)
        .union(JsStaticMemberExpression::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_EXPRESSION
                | JS_CALL_EXPRESSION
                | JS_IDENTIFIER_EXPRESSION
                | JS_PARENTHESIZED_EXPRESSION
                | JS_STATIC_MEMBER_EXPRESSION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_EXPRESSION => Self::JsBogusExpression(JsBogusExpression { syntax }),
            JS_CALL_EXPRESSION => Self::JsCallExpression(JsCallExpression { syntax }),
            JS_IDENTIFIER_EXPRESSION => {
                Self::JsIdentifierExpression(JsIdentifierExpression { syntax })
            }
            JS_PARENTHESIZED_EXPRESSION => {
                Self::JsParenthesizedExpression(JsParenthesizedExpression { syntax })
            }
            JS_STATIC_MEMBER_EXPRESSION => {
                Self::JsStaticMemberExpression(JsStaticMemberExpression { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusExpression(it) => it.syntax(),
            Self::JsCallExpression(it) => it.syntax(),
            Self::JsIdentifierExpression(it) => it.syntax(),
            Self::JsParenthesizedExpression(it) => it.syntax(),
            Self::JsStaticMemberExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusExpression(it) => it.into_syntax(),
            Self::JsCallExpression(it) => it.into_syntax(),
            Self::JsIdentifierExpression(it) => it.into_syntax(),
            Self::JsParenthesizedExpression(it) => it.into_syntax(),
            Self::JsStaticMemberExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsDecorator {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsCallExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsIdentifierExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsParenthesizedExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticMemberExpression(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsDecorator> for SyntaxNode {
    fn from(n: AnyJsDecorator) -> Self {
        match n {
            AnyJsDecorator::JsBogusExpression(it) => it.into_syntax(),
            AnyJsDecorator::JsCallExpression(it) => it.into_syntax(),
            AnyJsDecorator::JsIdentifierExpression(it) => it.into_syntax(),
            AnyJsDecorator::JsParenthesizedExpression(it) => it.into_syntax(),
            AnyJsDecorator::JsStaticMemberExpression(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsDecorator> for SyntaxElement {
    fn from(n: AnyJsDecorator) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsExportDefaultDeclarationClause> for AnyJsExportClause {
    fn from(node: JsExportDefaultDeclarationClause) -> Self {
        Self::JsExportDefaultDeclarationClause(node)
    }
}
impl From<JsExportDefaultExpressionClause> for AnyJsExportClause {
    fn from(node: JsExportDefaultExpressionClause) -> Self {
        Self::JsExportDefaultExpressionClause(node)
    }
}
impl From<JsExportFromClause> for AnyJsExportClause {
    fn from(node: JsExportFromClause) -> Self {
        Self::JsExportFromClause(node)
    }
}
impl From<JsExportNamedClause> for AnyJsExportClause {
    fn from(node: JsExportNamedClause) -> Self {
        Self::JsExportNamedClause(node)
    }
}
impl From<JsExportNamedFromClause> for AnyJsExportClause {
    fn from(node: JsExportNamedFromClause) -> Self {
        Self::JsExportNamedFromClause(node)
    }
}
impl From<TsExportAsNamespaceClause> for AnyJsExportClause {
    fn from(node: TsExportAsNamespaceClause) -> Self {
        Self::TsExportAsNamespaceClause(node)
    }
}
impl From<TsExportAssignmentClause> for AnyJsExportClause {
    fn from(node: TsExportAssignmentClause) -> Self {
        Self::TsExportAssignmentClause(node)
    }
}
impl From<TsExportDeclareClause> for AnyJsExportClause {
    fn from(node: TsExportDeclareClause) -> Self {
        Self::TsExportDeclareClause(node)
    }
}
impl AstNode for AnyJsExportClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsDeclarationClause::KIND_SET
        .union(JsExportDefaultDeclarationClause::KIND_SET)
        .union(JsExportDefaultExpressionClause::KIND_SET)
        .union(JsExportFromClause::KIND_SET)
        .union(JsExportNamedClause::KIND_SET)
        .union(JsExportNamedFromClause::KIND_SET)
        .union(TsExportAsNamespaceClause::KIND_SET)
        .union(TsExportAssignmentClause::KIND_SET)
        .union(TsExportDeclareClause::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_EXPORT_DEFAULT_DECLARATION_CLAUSE
            | JS_EXPORT_DEFAULT_EXPRESSION_CLAUSE
            | JS_EXPORT_FROM_CLAUSE
            | JS_EXPORT_NAMED_CLAUSE
            | JS_EXPORT_NAMED_FROM_CLAUSE
            | TS_EXPORT_AS_NAMESPACE_CLAUSE
            | TS_EXPORT_ASSIGNMENT_CLAUSE
            | TS_EXPORT_DECLARE_CLAUSE => true,
            k if AnyJsDeclarationClause::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_EXPORT_DEFAULT_DECLARATION_CLAUSE => {
                Self::JsExportDefaultDeclarationClause(JsExportDefaultDeclarationClause { syntax })
            }
            JS_EXPORT_DEFAULT_EXPRESSION_CLAUSE => {
                Self::JsExportDefaultExpressionClause(JsExportDefaultExpressionClause { syntax })
            }
            JS_EXPORT_FROM_CLAUSE => Self::JsExportFromClause(JsExportFromClause { syntax }),
            JS_EXPORT_NAMED_CLAUSE => Self::JsExportNamedClause(JsExportNamedClause { syntax }),
            JS_EXPORT_NAMED_FROM_CLAUSE => {
                Self::JsExportNamedFromClause(JsExportNamedFromClause { syntax })
            }
            TS_EXPORT_AS_NAMESPACE_CLAUSE => {
                Self::TsExportAsNamespaceClause(TsExportAsNamespaceClause { syntax })
            }
            TS_EXPORT_ASSIGNMENT_CLAUSE => {
                Self::TsExportAssignmentClause(TsExportAssignmentClause { syntax })
            }
            TS_EXPORT_DECLARE_CLAUSE => {
                Self::TsExportDeclareClause(TsExportDeclareClause { syntax })
            }
            _ => {
                if let Some(any_js_declaration_clause) = AnyJsDeclarationClause::cast(syntax) {
                    return Some(Self::AnyJsDeclarationClause(any_js_declaration_clause));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsExportDefaultDeclarationClause(it) => it.syntax(),
            Self::JsExportDefaultExpressionClause(it) => it.syntax(),
            Self::JsExportFromClause(it) => it.syntax(),
            Self::JsExportNamedClause(it) => it.syntax(),
            Self::JsExportNamedFromClause(it) => it.syntax(),
            Self::TsExportAsNamespaceClause(it) => it.syntax(),
            Self::TsExportAssignmentClause(it) => it.syntax(),
            Self::TsExportDeclareClause(it) => it.syntax(),
            Self::AnyJsDeclarationClause(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsExportDefaultDeclarationClause(it) => it.into_syntax(),
            Self::JsExportDefaultExpressionClause(it) => it.into_syntax(),
            Self::JsExportFromClause(it) => it.into_syntax(),
            Self::JsExportNamedClause(it) => it.into_syntax(),
            Self::JsExportNamedFromClause(it) => it.into_syntax(),
            Self::TsExportAsNamespaceClause(it) => it.into_syntax(),
            Self::TsExportAssignmentClause(it) => it.into_syntax(),
            Self::TsExportDeclareClause(it) => it.into_syntax(),
            Self::AnyJsDeclarationClause(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsExportClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsDeclarationClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExportDefaultDeclarationClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExportDefaultExpressionClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExportFromClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExportNamedClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExportNamedFromClause(it) => std::fmt::Debug::fmt(it, f),
            Self::TsExportAsNamespaceClause(it) => std::fmt::Debug::fmt(it, f),
            Self::TsExportAssignmentClause(it) => std::fmt::Debug::fmt(it, f),
            Self::TsExportDeclareClause(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsExportClause> for SyntaxNode {
    fn from(n: AnyJsExportClause) -> Self {
        match n {
            AnyJsExportClause::AnyJsDeclarationClause(it) => it.into_syntax(),
            AnyJsExportClause::JsExportDefaultDeclarationClause(it) => it.into_syntax(),
            AnyJsExportClause::JsExportDefaultExpressionClause(it) => it.into_syntax(),
            AnyJsExportClause::JsExportFromClause(it) => it.into_syntax(),
            AnyJsExportClause::JsExportNamedClause(it) => it.into_syntax(),
            AnyJsExportClause::JsExportNamedFromClause(it) => it.into_syntax(),
            AnyJsExportClause::TsExportAsNamespaceClause(it) => it.into_syntax(),
            AnyJsExportClause::TsExportAssignmentClause(it) => it.into_syntax(),
            AnyJsExportClause::TsExportDeclareClause(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsExportClause> for SyntaxElement {
    fn from(n: AnyJsExportClause) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsClassExportDefaultDeclaration> for AnyJsExportDefaultDeclaration {
    fn from(node: JsClassExportDefaultDeclaration) -> Self {
        Self::JsClassExportDefaultDeclaration(node)
    }
}
impl From<JsFunctionExportDefaultDeclaration> for AnyJsExportDefaultDeclaration {
    fn from(node: JsFunctionExportDefaultDeclaration) -> Self {
        Self::JsFunctionExportDefaultDeclaration(node)
    }
}
impl From<TsDeclareFunctionExportDefaultDeclaration> for AnyJsExportDefaultDeclaration {
    fn from(node: TsDeclareFunctionExportDefaultDeclaration) -> Self {
        Self::TsDeclareFunctionExportDefaultDeclaration(node)
    }
}
impl From<TsInterfaceDeclaration> for AnyJsExportDefaultDeclaration {
    fn from(node: TsInterfaceDeclaration) -> Self {
        Self::TsInterfaceDeclaration(node)
    }
}
impl AstNode for AnyJsExportDefaultDeclaration {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsClassExportDefaultDeclaration::KIND_SET
        .union(JsFunctionExportDefaultDeclaration::KIND_SET)
        .union(TsDeclareFunctionExportDefaultDeclaration::KIND_SET)
        .union(TsInterfaceDeclaration::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_CLASS_EXPORT_DEFAULT_DECLARATION
                | JS_FUNCTION_EXPORT_DEFAULT_DECLARATION
                | TS_DECLARE_FUNCTION_EXPORT_DEFAULT_DECLARATION
                | TS_INTERFACE_DECLARATION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_CLASS_EXPORT_DEFAULT_DECLARATION => {
                Self::JsClassExportDefaultDeclaration(JsClassExportDefaultDeclaration { syntax })
            }
            JS_FUNCTION_EXPORT_DEFAULT_DECLARATION => {
                Self::JsFunctionExportDefaultDeclaration(JsFunctionExportDefaultDeclaration {
                    syntax,
                })
            }
            TS_DECLARE_FUNCTION_EXPORT_DEFAULT_DECLARATION => {
                Self::TsDeclareFunctionExportDefaultDeclaration(
                    TsDeclareFunctionExportDefaultDeclaration { syntax },
                )
            }
            TS_INTERFACE_DECLARATION => {
                Self::TsInterfaceDeclaration(TsInterfaceDeclaration { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsClassExportDefaultDeclaration(it) => it.syntax(),
            Self::JsFunctionExportDefaultDeclaration(it) => it.syntax(),
            Self::TsDeclareFunctionExportDefaultDeclaration(it) => it.syntax(),
            Self::TsInterfaceDeclaration(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsClassExportDefaultDeclaration(it) => it.into_syntax(),
            Self::JsFunctionExportDefaultDeclaration(it) => it.into_syntax(),
            Self::TsDeclareFunctionExportDefaultDeclaration(it) => it.into_syntax(),
            Self::TsInterfaceDeclaration(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsClassExportDefaultDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionExportDefaultDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsDeclareFunctionExportDefaultDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInterfaceDeclaration(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsExportDefaultDeclaration> for SyntaxNode {
    fn from(n: AnyJsExportDefaultDeclaration) -> Self {
        match n {
            AnyJsExportDefaultDeclaration::JsClassExportDefaultDeclaration(it) => it.into_syntax(),
            AnyJsExportDefaultDeclaration::JsFunctionExportDefaultDeclaration(it) => {
                it.into_syntax()
            }
            AnyJsExportDefaultDeclaration::TsDeclareFunctionExportDefaultDeclaration(it) => {
                it.into_syntax()
            }
            AnyJsExportDefaultDeclaration::TsInterfaceDeclaration(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsExportDefaultDeclaration> for SyntaxElement {
    fn from(n: AnyJsExportDefaultDeclaration) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsExportNamedShorthandSpecifier> for AnyJsExportNamedSpecifier {
    fn from(node: JsExportNamedShorthandSpecifier) -> Self {
        Self::JsExportNamedShorthandSpecifier(node)
    }
}
impl From<JsExportNamedSpecifier> for AnyJsExportNamedSpecifier {
    fn from(node: JsExportNamedSpecifier) -> Self {
        Self::JsExportNamedSpecifier(node)
    }
}
impl AstNode for AnyJsExportNamedSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsExportNamedShorthandSpecifier::KIND_SET.union(JsExportNamedSpecifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_EXPORT_NAMED_SHORTHAND_SPECIFIER | JS_EXPORT_NAMED_SPECIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_EXPORT_NAMED_SHORTHAND_SPECIFIER => {
                Self::JsExportNamedShorthandSpecifier(JsExportNamedShorthandSpecifier { syntax })
            }
            JS_EXPORT_NAMED_SPECIFIER => {
                Self::JsExportNamedSpecifier(JsExportNamedSpecifier { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsExportNamedShorthandSpecifier(it) => it.syntax(),
            Self::JsExportNamedSpecifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsExportNamedShorthandSpecifier(it) => it.into_syntax(),
            Self::JsExportNamedSpecifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsExportNamedSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsExportNamedShorthandSpecifier(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExportNamedSpecifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsExportNamedSpecifier> for SyntaxNode {
    fn from(n: AnyJsExportNamedSpecifier) -> Self {
        match n {
            AnyJsExportNamedSpecifier::JsExportNamedShorthandSpecifier(it) => it.into_syntax(),
            AnyJsExportNamedSpecifier::JsExportNamedSpecifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsExportNamedSpecifier> for SyntaxElement {
    fn from(n: AnyJsExportNamedSpecifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsArrayExpression> for AnyJsExpression {
    fn from(node: JsArrayExpression) -> Self {
        Self::JsArrayExpression(node)
    }
}
impl From<JsArrowFunctionExpression> for AnyJsExpression {
    fn from(node: JsArrowFunctionExpression) -> Self {
        Self::JsArrowFunctionExpression(node)
    }
}
impl From<JsAssignmentExpression> for AnyJsExpression {
    fn from(node: JsAssignmentExpression) -> Self {
        Self::JsAssignmentExpression(node)
    }
}
impl From<JsAwaitExpression> for AnyJsExpression {
    fn from(node: JsAwaitExpression) -> Self {
        Self::JsAwaitExpression(node)
    }
}
impl From<JsBinaryExpression> for AnyJsExpression {
    fn from(node: JsBinaryExpression) -> Self {
        Self::JsBinaryExpression(node)
    }
}
impl From<JsBogusExpression> for AnyJsExpression {
    fn from(node: JsBogusExpression) -> Self {
        Self::JsBogusExpression(node)
    }
}
impl From<JsCallExpression> for AnyJsExpression {
    fn from(node: JsCallExpression) -> Self {
        Self::JsCallExpression(node)
    }
}
impl From<JsClassExpression> for AnyJsExpression {
    fn from(node: JsClassExpression) -> Self {
        Self::JsClassExpression(node)
    }
}
impl From<JsComputedMemberExpression> for AnyJsExpression {
    fn from(node: JsComputedMemberExpression) -> Self {
        Self::JsComputedMemberExpression(node)
    }
}
impl From<JsConditionalExpression> for AnyJsExpression {
    fn from(node: JsConditionalExpression) -> Self {
        Self::JsConditionalExpression(node)
    }
}
impl From<JsFunctionExpression> for AnyJsExpression {
    fn from(node: JsFunctionExpression) -> Self {
        Self::JsFunctionExpression(node)
    }
}
impl From<JsIdentifierExpression> for AnyJsExpression {
    fn from(node: JsIdentifierExpression) -> Self {
        Self::JsIdentifierExpression(node)
    }
}
impl From<JsImportCallExpression> for AnyJsExpression {
    fn from(node: JsImportCallExpression) -> Self {
        Self::JsImportCallExpression(node)
    }
}
impl From<JsImportMetaExpression> for AnyJsExpression {
    fn from(node: JsImportMetaExpression) -> Self {
        Self::JsImportMetaExpression(node)
    }
}
impl From<JsInExpression> for AnyJsExpression {
    fn from(node: JsInExpression) -> Self {
        Self::JsInExpression(node)
    }
}
impl From<JsInstanceofExpression> for AnyJsExpression {
    fn from(node: JsInstanceofExpression) -> Self {
        Self::JsInstanceofExpression(node)
    }
}
impl From<JsLogicalExpression> for AnyJsExpression {
    fn from(node: JsLogicalExpression) -> Self {
        Self::JsLogicalExpression(node)
    }
}
impl From<JsMetavariable> for AnyJsExpression {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsNewExpression> for AnyJsExpression {
    fn from(node: JsNewExpression) -> Self {
        Self::JsNewExpression(node)
    }
}
impl From<JsNewTargetExpression> for AnyJsExpression {
    fn from(node: JsNewTargetExpression) -> Self {
        Self::JsNewTargetExpression(node)
    }
}
impl From<JsObjectExpression> for AnyJsExpression {
    fn from(node: JsObjectExpression) -> Self {
        Self::JsObjectExpression(node)
    }
}
impl From<JsParenthesizedExpression> for AnyJsExpression {
    fn from(node: JsParenthesizedExpression) -> Self {
        Self::JsParenthesizedExpression(node)
    }
}
impl From<JsPostUpdateExpression> for AnyJsExpression {
    fn from(node: JsPostUpdateExpression) -> Self {
        Self::JsPostUpdateExpression(node)
    }
}
impl From<JsPreUpdateExpression> for AnyJsExpression {
    fn from(node: JsPreUpdateExpression) -> Self {
        Self::JsPreUpdateExpression(node)
    }
}
impl From<JsSequenceExpression> for AnyJsExpression {
    fn from(node: JsSequenceExpression) -> Self {
        Self::JsSequenceExpression(node)
    }
}
impl From<JsStaticMemberExpression> for AnyJsExpression {
    fn from(node: JsStaticMemberExpression) -> Self {
        Self::JsStaticMemberExpression(node)
    }
}
impl From<JsSuperExpression> for AnyJsExpression {
    fn from(node: JsSuperExpression) -> Self {
        Self::JsSuperExpression(node)
    }
}
impl From<JsTemplateExpression> for AnyJsExpression {
    fn from(node: JsTemplateExpression) -> Self {
        Self::JsTemplateExpression(node)
    }
}
impl From<JsThisExpression> for AnyJsExpression {
    fn from(node: JsThisExpression) -> Self {
        Self::JsThisExpression(node)
    }
}
impl From<JsUnaryExpression> for AnyJsExpression {
    fn from(node: JsUnaryExpression) -> Self {
        Self::JsUnaryExpression(node)
    }
}
impl From<JsYieldExpression> for AnyJsExpression {
    fn from(node: JsYieldExpression) -> Self {
        Self::JsYieldExpression(node)
    }
}
impl From<JsxTagExpression> for AnyJsExpression {
    fn from(node: JsxTagExpression) -> Self {
        Self::JsxTagExpression(node)
    }
}
impl From<TsAsExpression> for AnyJsExpression {
    fn from(node: TsAsExpression) -> Self {
        Self::TsAsExpression(node)
    }
}
impl From<TsInstantiationExpression> for AnyJsExpression {
    fn from(node: TsInstantiationExpression) -> Self {
        Self::TsInstantiationExpression(node)
    }
}
impl From<TsNonNullAssertionExpression> for AnyJsExpression {
    fn from(node: TsNonNullAssertionExpression) -> Self {
        Self::TsNonNullAssertionExpression(node)
    }
}
impl From<TsSatisfiesExpression> for AnyJsExpression {
    fn from(node: TsSatisfiesExpression) -> Self {
        Self::TsSatisfiesExpression(node)
    }
}
impl From<TsTypeAssertionExpression> for AnyJsExpression {
    fn from(node: TsTypeAssertionExpression) -> Self {
        Self::TsTypeAssertionExpression(node)
    }
}
impl AstNode for AnyJsExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsLiteralExpression::KIND_SET
        .union(JsArrayExpression::KIND_SET)
        .union(JsArrowFunctionExpression::KIND_SET)
        .union(JsAssignmentExpression::KIND_SET)
        .union(JsAwaitExpression::KIND_SET)
        .union(JsBinaryExpression::KIND_SET)
        .union(JsBogusExpression::KIND_SET)
        .union(JsCallExpression::KIND_SET)
        .union(JsClassExpression::KIND_SET)
        .union(JsComputedMemberExpression::KIND_SET)
        .union(JsConditionalExpression::KIND_SET)
        .union(JsFunctionExpression::KIND_SET)
        .union(JsIdentifierExpression::KIND_SET)
        .union(JsImportCallExpression::KIND_SET)
        .union(JsImportMetaExpression::KIND_SET)
        .union(JsInExpression::KIND_SET)
        .union(JsInstanceofExpression::KIND_SET)
        .union(JsLogicalExpression::KIND_SET)
        .union(JsMetavariable::KIND_SET)
        .union(JsNewExpression::KIND_SET)
        .union(JsNewTargetExpression::KIND_SET)
        .union(JsObjectExpression::KIND_SET)
        .union(JsParenthesizedExpression::KIND_SET)
        .union(JsPostUpdateExpression::KIND_SET)
        .union(JsPreUpdateExpression::KIND_SET)
        .union(JsSequenceExpression::KIND_SET)
        .union(JsStaticMemberExpression::KIND_SET)
        .union(JsSuperExpression::KIND_SET)
        .union(JsTemplateExpression::KIND_SET)
        .union(JsThisExpression::KIND_SET)
        .union(JsUnaryExpression::KIND_SET)
        .union(JsYieldExpression::KIND_SET)
        .union(JsxTagExpression::KIND_SET)
        .union(TsAsExpression::KIND_SET)
        .union(TsInstantiationExpression::KIND_SET)
        .union(TsNonNullAssertionExpression::KIND_SET)
        .union(TsSatisfiesExpression::KIND_SET)
        .union(TsTypeAssertionExpression::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_ARRAY_EXPRESSION
            | JS_ARROW_FUNCTION_EXPRESSION
            | JS_ASSIGNMENT_EXPRESSION
            | JS_AWAIT_EXPRESSION
            | JS_BINARY_EXPRESSION
            | JS_BOGUS_EXPRESSION
            | JS_CALL_EXPRESSION
            | JS_CLASS_EXPRESSION
            | JS_COMPUTED_MEMBER_EXPRESSION
            | JS_CONDITIONAL_EXPRESSION
            | JS_FUNCTION_EXPRESSION
            | JS_IDENTIFIER_EXPRESSION
            | JS_IMPORT_CALL_EXPRESSION
            | JS_IMPORT_META_EXPRESSION
            | JS_IN_EXPRESSION
            | JS_INSTANCEOF_EXPRESSION
            | JS_LOGICAL_EXPRESSION
            | JS_METAVARIABLE
            | JS_NEW_EXPRESSION
            | JS_NEW_TARGET_EXPRESSION
            | JS_OBJECT_EXPRESSION
            | JS_PARENTHESIZED_EXPRESSION
            | JS_POST_UPDATE_EXPRESSION
            | JS_PRE_UPDATE_EXPRESSION
            | JS_SEQUENCE_EXPRESSION
            | JS_STATIC_MEMBER_EXPRESSION
            | JS_SUPER_EXPRESSION
            | JS_TEMPLATE_EXPRESSION
            | JS_THIS_EXPRESSION
            | JS_UNARY_EXPRESSION
            | JS_YIELD_EXPRESSION
            | JSX_TAG_EXPRESSION
            | TS_AS_EXPRESSION
            | TS_INSTANTIATION_EXPRESSION
            | TS_NON_NULL_ASSERTION_EXPRESSION
            | TS_SATISFIES_EXPRESSION
            | TS_TYPE_ASSERTION_EXPRESSION => true,
            k if AnyJsLiteralExpression::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ARRAY_EXPRESSION => Self::JsArrayExpression(JsArrayExpression { syntax }),
            JS_ARROW_FUNCTION_EXPRESSION => {
                Self::JsArrowFunctionExpression(JsArrowFunctionExpression { syntax })
            }
            JS_ASSIGNMENT_EXPRESSION => {
                Self::JsAssignmentExpression(JsAssignmentExpression { syntax })
            }
            JS_AWAIT_EXPRESSION => Self::JsAwaitExpression(JsAwaitExpression { syntax }),
            JS_BINARY_EXPRESSION => Self::JsBinaryExpression(JsBinaryExpression { syntax }),
            JS_BOGUS_EXPRESSION => Self::JsBogusExpression(JsBogusExpression { syntax }),
            JS_CALL_EXPRESSION => Self::JsCallExpression(JsCallExpression { syntax }),
            JS_CLASS_EXPRESSION => Self::JsClassExpression(JsClassExpression { syntax }),
            JS_COMPUTED_MEMBER_EXPRESSION => {
                Self::JsComputedMemberExpression(JsComputedMemberExpression { syntax })
            }
            JS_CONDITIONAL_EXPRESSION => {
                Self::JsConditionalExpression(JsConditionalExpression { syntax })
            }
            JS_FUNCTION_EXPRESSION => Self::JsFunctionExpression(JsFunctionExpression { syntax }),
            JS_IDENTIFIER_EXPRESSION => {
                Self::JsIdentifierExpression(JsIdentifierExpression { syntax })
            }
            JS_IMPORT_CALL_EXPRESSION => {
                Self::JsImportCallExpression(JsImportCallExpression { syntax })
            }
            JS_IMPORT_META_EXPRESSION => {
                Self::JsImportMetaExpression(JsImportMetaExpression { syntax })
            }
            JS_IN_EXPRESSION => Self::JsInExpression(JsInExpression { syntax }),
            JS_INSTANCEOF_EXPRESSION => {
                Self::JsInstanceofExpression(JsInstanceofExpression { syntax })
            }
            JS_LOGICAL_EXPRESSION => Self::JsLogicalExpression(JsLogicalExpression { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_NEW_EXPRESSION => Self::JsNewExpression(JsNewExpression { syntax }),
            JS_NEW_TARGET_EXPRESSION => {
                Self::JsNewTargetExpression(JsNewTargetExpression { syntax })
            }
            JS_OBJECT_EXPRESSION => Self::JsObjectExpression(JsObjectExpression { syntax }),
            JS_PARENTHESIZED_EXPRESSION => {
                Self::JsParenthesizedExpression(JsParenthesizedExpression { syntax })
            }
            JS_POST_UPDATE_EXPRESSION => {
                Self::JsPostUpdateExpression(JsPostUpdateExpression { syntax })
            }
            JS_PRE_UPDATE_EXPRESSION => {
                Self::JsPreUpdateExpression(JsPreUpdateExpression { syntax })
            }
            JS_SEQUENCE_EXPRESSION => Self::JsSequenceExpression(JsSequenceExpression { syntax }),
            JS_STATIC_MEMBER_EXPRESSION => {
                Self::JsStaticMemberExpression(JsStaticMemberExpression { syntax })
            }
            JS_SUPER_EXPRESSION => Self::JsSuperExpression(JsSuperExpression { syntax }),
            JS_TEMPLATE_EXPRESSION => Self::JsTemplateExpression(JsTemplateExpression { syntax }),
            JS_THIS_EXPRESSION => Self::JsThisExpression(JsThisExpression { syntax }),
            JS_UNARY_EXPRESSION => Self::JsUnaryExpression(JsUnaryExpression { syntax }),
            JS_YIELD_EXPRESSION => Self::JsYieldExpression(JsYieldExpression { syntax }),
            JSX_TAG_EXPRESSION => Self::JsxTagExpression(JsxTagExpression { syntax }),
            TS_AS_EXPRESSION => Self::TsAsExpression(TsAsExpression { syntax }),
            TS_INSTANTIATION_EXPRESSION => {
                Self::TsInstantiationExpression(TsInstantiationExpression { syntax })
            }
            TS_NON_NULL_ASSERTION_EXPRESSION => {
                Self::TsNonNullAssertionExpression(TsNonNullAssertionExpression { syntax })
            }
            TS_SATISFIES_EXPRESSION => {
                Self::TsSatisfiesExpression(TsSatisfiesExpression { syntax })
            }
            TS_TYPE_ASSERTION_EXPRESSION => {
                Self::TsTypeAssertionExpression(TsTypeAssertionExpression { syntax })
            }
            _ => {
                if let Some(any_js_literal_expression) = AnyJsLiteralExpression::cast(syntax) {
                    return Some(Self::AnyJsLiteralExpression(any_js_literal_expression));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsArrayExpression(it) => it.syntax(),
            Self::JsArrowFunctionExpression(it) => it.syntax(),
            Self::JsAssignmentExpression(it) => it.syntax(),
            Self::JsAwaitExpression(it) => it.syntax(),
            Self::JsBinaryExpression(it) => it.syntax(),
            Self::JsBogusExpression(it) => it.syntax(),
            Self::JsCallExpression(it) => it.syntax(),
            Self::JsClassExpression(it) => it.syntax(),
            Self::JsComputedMemberExpression(it) => it.syntax(),
            Self::JsConditionalExpression(it) => it.syntax(),
            Self::JsFunctionExpression(it) => it.syntax(),
            Self::JsIdentifierExpression(it) => it.syntax(),
            Self::JsImportCallExpression(it) => it.syntax(),
            Self::JsImportMetaExpression(it) => it.syntax(),
            Self::JsInExpression(it) => it.syntax(),
            Self::JsInstanceofExpression(it) => it.syntax(),
            Self::JsLogicalExpression(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsNewExpression(it) => it.syntax(),
            Self::JsNewTargetExpression(it) => it.syntax(),
            Self::JsObjectExpression(it) => it.syntax(),
            Self::JsParenthesizedExpression(it) => it.syntax(),
            Self::JsPostUpdateExpression(it) => it.syntax(),
            Self::JsPreUpdateExpression(it) => it.syntax(),
            Self::JsSequenceExpression(it) => it.syntax(),
            Self::JsStaticMemberExpression(it) => it.syntax(),
            Self::JsSuperExpression(it) => it.syntax(),
            Self::JsTemplateExpression(it) => it.syntax(),
            Self::JsThisExpression(it) => it.syntax(),
            Self::JsUnaryExpression(it) => it.syntax(),
            Self::JsYieldExpression(it) => it.syntax(),
            Self::JsxTagExpression(it) => it.syntax(),
            Self::TsAsExpression(it) => it.syntax(),
            Self::TsInstantiationExpression(it) => it.syntax(),
            Self::TsNonNullAssertionExpression(it) => it.syntax(),
            Self::TsSatisfiesExpression(it) => it.syntax(),
            Self::TsTypeAssertionExpression(it) => it.syntax(),
            Self::AnyJsLiteralExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsArrayExpression(it) => it.into_syntax(),
            Self::JsArrowFunctionExpression(it) => it.into_syntax(),
            Self::JsAssignmentExpression(it) => it.into_syntax(),
            Self::JsAwaitExpression(it) => it.into_syntax(),
            Self::JsBinaryExpression(it) => it.into_syntax(),
            Self::JsBogusExpression(it) => it.into_syntax(),
            Self::JsCallExpression(it) => it.into_syntax(),
            Self::JsClassExpression(it) => it.into_syntax(),
            Self::JsComputedMemberExpression(it) => it.into_syntax(),
            Self::JsConditionalExpression(it) => it.into_syntax(),
            Self::JsFunctionExpression(it) => it.into_syntax(),
            Self::JsIdentifierExpression(it) => it.into_syntax(),
            Self::JsImportCallExpression(it) => it.into_syntax(),
            Self::JsImportMetaExpression(it) => it.into_syntax(),
            Self::JsInExpression(it) => it.into_syntax(),
            Self::JsInstanceofExpression(it) => it.into_syntax(),
            Self::JsLogicalExpression(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsNewExpression(it) => it.into_syntax(),
            Self::JsNewTargetExpression(it) => it.into_syntax(),
            Self::JsObjectExpression(it) => it.into_syntax(),
            Self::JsParenthesizedExpression(it) => it.into_syntax(),
            Self::JsPostUpdateExpression(it) => it.into_syntax(),
            Self::JsPreUpdateExpression(it) => it.into_syntax(),
            Self::JsSequenceExpression(it) => it.into_syntax(),
            Self::JsStaticMemberExpression(it) => it.into_syntax(),
            Self::JsSuperExpression(it) => it.into_syntax(),
            Self::JsTemplateExpression(it) => it.into_syntax(),
            Self::JsThisExpression(it) => it.into_syntax(),
            Self::JsUnaryExpression(it) => it.into_syntax(),
            Self::JsYieldExpression(it) => it.into_syntax(),
            Self::JsxTagExpression(it) => it.into_syntax(),
            Self::TsAsExpression(it) => it.into_syntax(),
            Self::TsInstantiationExpression(it) => it.into_syntax(),
            Self::TsNonNullAssertionExpression(it) => it.into_syntax(),
            Self::TsSatisfiesExpression(it) => it.into_syntax(),
            Self::TsTypeAssertionExpression(it) => it.into_syntax(),
            Self::AnyJsLiteralExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsLiteralExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrayExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsArrowFunctionExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsAssignmentExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsAwaitExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsBinaryExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsBogusExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsCallExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsClassExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsComputedMemberExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsConditionalExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsIdentifierExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImportCallExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImportMetaExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsInExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsInstanceofExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsLogicalExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsNewExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsNewTargetExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsParenthesizedExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsPostUpdateExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsPreUpdateExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSequenceExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticMemberExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSuperExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsTemplateExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsThisExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsUnaryExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsYieldExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxTagExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAsExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInstantiationExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNonNullAssertionExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::TsSatisfiesExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAssertionExpression(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsExpression> for SyntaxNode {
    fn from(n: AnyJsExpression) -> Self {
        match n {
            AnyJsExpression::AnyJsLiteralExpression(it) => it.into_syntax(),
            AnyJsExpression::JsArrayExpression(it) => it.into_syntax(),
            AnyJsExpression::JsArrowFunctionExpression(it) => it.into_syntax(),
            AnyJsExpression::JsAssignmentExpression(it) => it.into_syntax(),
            AnyJsExpression::JsAwaitExpression(it) => it.into_syntax(),
            AnyJsExpression::JsBinaryExpression(it) => it.into_syntax(),
            AnyJsExpression::JsBogusExpression(it) => it.into_syntax(),
            AnyJsExpression::JsCallExpression(it) => it.into_syntax(),
            AnyJsExpression::JsClassExpression(it) => it.into_syntax(),
            AnyJsExpression::JsComputedMemberExpression(it) => it.into_syntax(),
            AnyJsExpression::JsConditionalExpression(it) => it.into_syntax(),
            AnyJsExpression::JsFunctionExpression(it) => it.into_syntax(),
            AnyJsExpression::JsIdentifierExpression(it) => it.into_syntax(),
            AnyJsExpression::JsImportCallExpression(it) => it.into_syntax(),
            AnyJsExpression::JsImportMetaExpression(it) => it.into_syntax(),
            AnyJsExpression::JsInExpression(it) => it.into_syntax(),
            AnyJsExpression::JsInstanceofExpression(it) => it.into_syntax(),
            AnyJsExpression::JsLogicalExpression(it) => it.into_syntax(),
            AnyJsExpression::JsMetavariable(it) => it.into_syntax(),
            AnyJsExpression::JsNewExpression(it) => it.into_syntax(),
            AnyJsExpression::JsNewTargetExpression(it) => it.into_syntax(),
            AnyJsExpression::JsObjectExpression(it) => it.into_syntax(),
            AnyJsExpression::JsParenthesizedExpression(it) => it.into_syntax(),
            AnyJsExpression::JsPostUpdateExpression(it) => it.into_syntax(),
            AnyJsExpression::JsPreUpdateExpression(it) => it.into_syntax(),
            AnyJsExpression::JsSequenceExpression(it) => it.into_syntax(),
            AnyJsExpression::JsStaticMemberExpression(it) => it.into_syntax(),
            AnyJsExpression::JsSuperExpression(it) => it.into_syntax(),
            AnyJsExpression::JsTemplateExpression(it) => it.into_syntax(),
            AnyJsExpression::JsThisExpression(it) => it.into_syntax(),
            AnyJsExpression::JsUnaryExpression(it) => it.into_syntax(),
            AnyJsExpression::JsYieldExpression(it) => it.into_syntax(),
            AnyJsExpression::JsxTagExpression(it) => it.into_syntax(),
            AnyJsExpression::TsAsExpression(it) => it.into_syntax(),
            AnyJsExpression::TsInstantiationExpression(it) => it.into_syntax(),
            AnyJsExpression::TsNonNullAssertionExpression(it) => it.into_syntax(),
            AnyJsExpression::TsSatisfiesExpression(it) => it.into_syntax(),
            AnyJsExpression::TsTypeAssertionExpression(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsExpression> for SyntaxElement {
    fn from(n: AnyJsExpression) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsForVariableDeclaration> for AnyJsForInOrOfInitializer {
    fn from(node: JsForVariableDeclaration) -> Self {
        Self::JsForVariableDeclaration(node)
    }
}
impl AstNode for AnyJsForInOrOfInitializer {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        AnyJsAssignmentPattern::KIND_SET.union(JsForVariableDeclaration::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_FOR_VARIABLE_DECLARATION => true,
            k if AnyJsAssignmentPattern::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_FOR_VARIABLE_DECLARATION => {
                Self::JsForVariableDeclaration(JsForVariableDeclaration { syntax })
            }
            _ => {
                if let Some(any_js_assignment_pattern) = AnyJsAssignmentPattern::cast(syntax) {
                    return Some(Self::AnyJsAssignmentPattern(any_js_assignment_pattern));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsForVariableDeclaration(it) => it.syntax(),
            Self::AnyJsAssignmentPattern(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsForVariableDeclaration(it) => it.into_syntax(),
            Self::AnyJsAssignmentPattern(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsForInOrOfInitializer {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsAssignmentPattern(it) => std::fmt::Debug::fmt(it, f),
            Self::JsForVariableDeclaration(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsForInOrOfInitializer> for SyntaxNode {
    fn from(n: AnyJsForInOrOfInitializer) -> Self {
        match n {
            AnyJsForInOrOfInitializer::AnyJsAssignmentPattern(it) => it.into_syntax(),
            AnyJsForInOrOfInitializer::JsForVariableDeclaration(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsForInOrOfInitializer> for SyntaxElement {
    fn from(n: AnyJsForInOrOfInitializer) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsVariableDeclaration> for AnyJsForInitializer {
    fn from(node: JsVariableDeclaration) -> Self {
        Self::JsVariableDeclaration(node)
    }
}
impl AstNode for AnyJsForInitializer {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        AnyJsExpression::KIND_SET.union(JsVariableDeclaration::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_VARIABLE_DECLARATION => true,
            k if AnyJsExpression::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_VARIABLE_DECLARATION => {
                Self::JsVariableDeclaration(JsVariableDeclaration { syntax })
            }
            _ => {
                if let Some(any_js_expression) = AnyJsExpression::cast(syntax) {
                    return Some(Self::AnyJsExpression(any_js_expression));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsVariableDeclaration(it) => it.syntax(),
            Self::AnyJsExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsVariableDeclaration(it) => it.into_syntax(),
            Self::AnyJsExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsForInitializer {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsVariableDeclaration(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsForInitializer> for SyntaxNode {
    fn from(n: AnyJsForInitializer) -> Self {
        match n {
            AnyJsForInitializer::AnyJsExpression(it) => it.into_syntax(),
            AnyJsForInitializer::JsVariableDeclaration(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsForInitializer> for SyntaxElement {
    fn from(n: AnyJsForInitializer) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusParameter> for AnyJsFormalParameter {
    fn from(node: JsBogusParameter) -> Self {
        Self::JsBogusParameter(node)
    }
}
impl From<JsFormalParameter> for AnyJsFormalParameter {
    fn from(node: JsFormalParameter) -> Self {
        Self::JsFormalParameter(node)
    }
}
impl From<JsMetavariable> for AnyJsFormalParameter {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl AstNode for AnyJsFormalParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusParameter::KIND_SET
        .union(JsFormalParameter::KIND_SET)
        .union(JsMetavariable::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_PARAMETER | JS_FORMAL_PARAMETER | JS_METAVARIABLE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_PARAMETER => Self::JsBogusParameter(JsBogusParameter { syntax }),
            JS_FORMAL_PARAMETER => Self::JsFormalParameter(JsFormalParameter { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusParameter(it) => it.syntax(),
            Self::JsFormalParameter(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusParameter(it) => it.into_syntax(),
            Self::JsFormalParameter(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsFormalParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusParameter(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFormalParameter(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsFormalParameter> for SyntaxNode {
    fn from(n: AnyJsFormalParameter) -> Self {
        match n {
            AnyJsFormalParameter::JsBogusParameter(it) => it.into_syntax(),
            AnyJsFormalParameter::JsFormalParameter(it) => it.into_syntax(),
            AnyJsFormalParameter::JsMetavariable(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsFormalParameter> for SyntaxElement {
    fn from(n: AnyJsFormalParameter) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsArrowFunctionExpression> for AnyJsFunction {
    fn from(node: JsArrowFunctionExpression) -> Self {
        Self::JsArrowFunctionExpression(node)
    }
}
impl From<JsFunctionDeclaration> for AnyJsFunction {
    fn from(node: JsFunctionDeclaration) -> Self {
        Self::JsFunctionDeclaration(node)
    }
}
impl From<JsFunctionExportDefaultDeclaration> for AnyJsFunction {
    fn from(node: JsFunctionExportDefaultDeclaration) -> Self {
        Self::JsFunctionExportDefaultDeclaration(node)
    }
}
impl From<JsFunctionExpression> for AnyJsFunction {
    fn from(node: JsFunctionExpression) -> Self {
        Self::JsFunctionExpression(node)
    }
}
impl AstNode for AnyJsFunction {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsArrowFunctionExpression::KIND_SET
        .union(JsFunctionDeclaration::KIND_SET)
        .union(JsFunctionExportDefaultDeclaration::KIND_SET)
        .union(JsFunctionExpression::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_ARROW_FUNCTION_EXPRESSION
                | JS_FUNCTION_DECLARATION
                | JS_FUNCTION_EXPORT_DEFAULT_DECLARATION
                | JS_FUNCTION_EXPRESSION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ARROW_FUNCTION_EXPRESSION => {
                Self::JsArrowFunctionExpression(JsArrowFunctionExpression { syntax })
            }
            JS_FUNCTION_DECLARATION => {
                Self::JsFunctionDeclaration(JsFunctionDeclaration { syntax })
            }
            JS_FUNCTION_EXPORT_DEFAULT_DECLARATION => {
                Self::JsFunctionExportDefaultDeclaration(JsFunctionExportDefaultDeclaration {
                    syntax,
                })
            }
            JS_FUNCTION_EXPRESSION => Self::JsFunctionExpression(JsFunctionExpression { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsArrowFunctionExpression(it) => it.syntax(),
            Self::JsFunctionDeclaration(it) => it.syntax(),
            Self::JsFunctionExportDefaultDeclaration(it) => it.syntax(),
            Self::JsFunctionExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsArrowFunctionExpression(it) => it.into_syntax(),
            Self::JsFunctionDeclaration(it) => it.into_syntax(),
            Self::JsFunctionExportDefaultDeclaration(it) => it.into_syntax(),
            Self::JsFunctionExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsFunction {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsArrowFunctionExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionExportDefaultDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionExpression(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsFunction> for SyntaxNode {
    fn from(n: AnyJsFunction) -> Self {
        match n {
            AnyJsFunction::JsArrowFunctionExpression(it) => it.into_syntax(),
            AnyJsFunction::JsFunctionDeclaration(it) => it.into_syntax(),
            AnyJsFunction::JsFunctionExportDefaultDeclaration(it) => it.into_syntax(),
            AnyJsFunction::JsFunctionExpression(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsFunction> for SyntaxElement {
    fn from(n: AnyJsFunction) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsFunctionBody> for AnyJsFunctionBody {
    fn from(node: JsFunctionBody) -> Self {
        Self::JsFunctionBody(node)
    }
}
impl AstNode for AnyJsFunctionBody {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        AnyJsExpression::KIND_SET.union(JsFunctionBody::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_FUNCTION_BODY => true,
            k if AnyJsExpression::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_FUNCTION_BODY => Self::JsFunctionBody(JsFunctionBody { syntax }),
            _ => {
                if let Some(any_js_expression) = AnyJsExpression::cast(syntax) {
                    return Some(Self::AnyJsExpression(any_js_expression));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsFunctionBody(it) => it.syntax(),
            Self::AnyJsExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsFunctionBody(it) => it.into_syntax(),
            Self::AnyJsExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsFunctionBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionBody(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsFunctionBody> for SyntaxNode {
    fn from(n: AnyJsFunctionBody) -> Self {
        match n {
            AnyJsFunctionBody::AnyJsExpression(it) => it.into_syntax(),
            AnyJsFunctionBody::JsFunctionBody(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsFunctionBody> for SyntaxElement {
    fn from(n: AnyJsFunctionBody) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusImportAssertionEntry> for AnyJsImportAssertionEntry {
    fn from(node: JsBogusImportAssertionEntry) -> Self {
        Self::JsBogusImportAssertionEntry(node)
    }
}
impl From<JsImportAssertionEntry> for AnyJsImportAssertionEntry {
    fn from(node: JsImportAssertionEntry) -> Self {
        Self::JsImportAssertionEntry(node)
    }
}
impl AstNode for AnyJsImportAssertionEntry {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsBogusImportAssertionEntry::KIND_SET.union(JsImportAssertionEntry::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_IMPORT_ASSERTION_ENTRY | JS_IMPORT_ASSERTION_ENTRY
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_IMPORT_ASSERTION_ENTRY => {
                Self::JsBogusImportAssertionEntry(JsBogusImportAssertionEntry { syntax })
            }
            JS_IMPORT_ASSERTION_ENTRY => {
                Self::JsImportAssertionEntry(JsImportAssertionEntry { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusImportAssertionEntry(it) => it.syntax(),
            Self::JsImportAssertionEntry(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusImportAssertionEntry(it) => it.into_syntax(),
            Self::JsImportAssertionEntry(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsImportAssertionEntry {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusImportAssertionEntry(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImportAssertionEntry(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsImportAssertionEntry> for SyntaxNode {
    fn from(n: AnyJsImportAssertionEntry) -> Self {
        match n {
            AnyJsImportAssertionEntry::JsBogusImportAssertionEntry(it) => it.into_syntax(),
            AnyJsImportAssertionEntry::JsImportAssertionEntry(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsImportAssertionEntry> for SyntaxElement {
    fn from(n: AnyJsImportAssertionEntry) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsImportBareClause> for AnyJsImportClause {
    fn from(node: JsImportBareClause) -> Self {
        Self::JsImportBareClause(node)
    }
}
impl From<JsImportCombinedClause> for AnyJsImportClause {
    fn from(node: JsImportCombinedClause) -> Self {
        Self::JsImportCombinedClause(node)
    }
}
impl From<JsImportDefaultClause> for AnyJsImportClause {
    fn from(node: JsImportDefaultClause) -> Self {
        Self::JsImportDefaultClause(node)
    }
}
impl From<JsImportNamedClause> for AnyJsImportClause {
    fn from(node: JsImportNamedClause) -> Self {
        Self::JsImportNamedClause(node)
    }
}
impl From<JsImportNamespaceClause> for AnyJsImportClause {
    fn from(node: JsImportNamespaceClause) -> Self {
        Self::JsImportNamespaceClause(node)
    }
}
impl AstNode for AnyJsImportClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsImportBareClause::KIND_SET
        .union(JsImportCombinedClause::KIND_SET)
        .union(JsImportDefaultClause::KIND_SET)
        .union(JsImportNamedClause::KIND_SET)
        .union(JsImportNamespaceClause::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_IMPORT_BARE_CLAUSE
                | JS_IMPORT_COMBINED_CLAUSE
                | JS_IMPORT_DEFAULT_CLAUSE
                | JS_IMPORT_NAMED_CLAUSE
                | JS_IMPORT_NAMESPACE_CLAUSE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_IMPORT_BARE_CLAUSE => Self::JsImportBareClause(JsImportBareClause { syntax }),
            JS_IMPORT_COMBINED_CLAUSE => {
                Self::JsImportCombinedClause(JsImportCombinedClause { syntax })
            }
            JS_IMPORT_DEFAULT_CLAUSE => {
                Self::JsImportDefaultClause(JsImportDefaultClause { syntax })
            }
            JS_IMPORT_NAMED_CLAUSE => Self::JsImportNamedClause(JsImportNamedClause { syntax }),
            JS_IMPORT_NAMESPACE_CLAUSE => {
                Self::JsImportNamespaceClause(JsImportNamespaceClause { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsImportBareClause(it) => it.syntax(),
            Self::JsImportCombinedClause(it) => it.syntax(),
            Self::JsImportDefaultClause(it) => it.syntax(),
            Self::JsImportNamedClause(it) => it.syntax(),
            Self::JsImportNamespaceClause(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsImportBareClause(it) => it.into_syntax(),
            Self::JsImportCombinedClause(it) => it.into_syntax(),
            Self::JsImportDefaultClause(it) => it.into_syntax(),
            Self::JsImportNamedClause(it) => it.into_syntax(),
            Self::JsImportNamespaceClause(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsImportClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsImportBareClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImportCombinedClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImportDefaultClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImportNamedClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImportNamespaceClause(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsImportClause> for SyntaxNode {
    fn from(n: AnyJsImportClause) -> Self {
        match n {
            AnyJsImportClause::JsImportBareClause(it) => it.into_syntax(),
            AnyJsImportClause::JsImportCombinedClause(it) => it.into_syntax(),
            AnyJsImportClause::JsImportDefaultClause(it) => it.into_syntax(),
            AnyJsImportClause::JsImportNamedClause(it) => it.into_syntax(),
            AnyJsImportClause::JsImportNamespaceClause(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsImportClause> for SyntaxElement {
    fn from(n: AnyJsImportClause) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsPrivateName> for AnyJsInProperty {
    fn from(node: JsPrivateName) -> Self {
        Self::JsPrivateName(node)
    }
}
impl AstNode for AnyJsInProperty {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        AnyJsExpression::KIND_SET.union(JsPrivateName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_PRIVATE_NAME => true,
            k if AnyJsExpression::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_PRIVATE_NAME => Self::JsPrivateName(JsPrivateName { syntax }),
            _ => {
                if let Some(any_js_expression) = AnyJsExpression::cast(syntax) {
                    return Some(Self::AnyJsExpression(any_js_expression));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsPrivateName(it) => it.syntax(),
            Self::AnyJsExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsPrivateName(it) => it.into_syntax(),
            Self::AnyJsExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsInProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsPrivateName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsInProperty> for SyntaxNode {
    fn from(n: AnyJsInProperty) -> Self {
        match n {
            AnyJsInProperty::AnyJsExpression(it) => it.into_syntax(),
            AnyJsInProperty::JsPrivateName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsInProperty> for SyntaxElement {
    fn from(n: AnyJsInProperty) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBigintLiteralExpression> for AnyJsLiteralExpression {
    fn from(node: JsBigintLiteralExpression) -> Self {
        Self::JsBigintLiteralExpression(node)
    }
}
impl From<JsBooleanLiteralExpression> for AnyJsLiteralExpression {
    fn from(node: JsBooleanLiteralExpression) -> Self {
        Self::JsBooleanLiteralExpression(node)
    }
}
impl From<JsNullLiteralExpression> for AnyJsLiteralExpression {
    fn from(node: JsNullLiteralExpression) -> Self {
        Self::JsNullLiteralExpression(node)
    }
}
impl From<JsNumberLiteralExpression> for AnyJsLiteralExpression {
    fn from(node: JsNumberLiteralExpression) -> Self {
        Self::JsNumberLiteralExpression(node)
    }
}
impl From<JsRegexLiteralExpression> for AnyJsLiteralExpression {
    fn from(node: JsRegexLiteralExpression) -> Self {
        Self::JsRegexLiteralExpression(node)
    }
}
impl From<JsStringLiteralExpression> for AnyJsLiteralExpression {
    fn from(node: JsStringLiteralExpression) -> Self {
        Self::JsStringLiteralExpression(node)
    }
}
impl AstNode for AnyJsLiteralExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBigintLiteralExpression::KIND_SET
        .union(JsBooleanLiteralExpression::KIND_SET)
        .union(JsNullLiteralExpression::KIND_SET)
        .union(JsNumberLiteralExpression::KIND_SET)
        .union(JsRegexLiteralExpression::KIND_SET)
        .union(JsStringLiteralExpression::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BIGINT_LITERAL_EXPRESSION
                | JS_BOOLEAN_LITERAL_EXPRESSION
                | JS_NULL_LITERAL_EXPRESSION
                | JS_NUMBER_LITERAL_EXPRESSION
                | JS_REGEX_LITERAL_EXPRESSION
                | JS_STRING_LITERAL_EXPRESSION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BIGINT_LITERAL_EXPRESSION => {
                Self::JsBigintLiteralExpression(JsBigintLiteralExpression { syntax })
            }
            JS_BOOLEAN_LITERAL_EXPRESSION => {
                Self::JsBooleanLiteralExpression(JsBooleanLiteralExpression { syntax })
            }
            JS_NULL_LITERAL_EXPRESSION => {
                Self::JsNullLiteralExpression(JsNullLiteralExpression { syntax })
            }
            JS_NUMBER_LITERAL_EXPRESSION => {
                Self::JsNumberLiteralExpression(JsNumberLiteralExpression { syntax })
            }
            JS_REGEX_LITERAL_EXPRESSION => {
                Self::JsRegexLiteralExpression(JsRegexLiteralExpression { syntax })
            }
            JS_STRING_LITERAL_EXPRESSION => {
                Self::JsStringLiteralExpression(JsStringLiteralExpression { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBigintLiteralExpression(it) => it.syntax(),
            Self::JsBooleanLiteralExpression(it) => it.syntax(),
            Self::JsNullLiteralExpression(it) => it.syntax(),
            Self::JsNumberLiteralExpression(it) => it.syntax(),
            Self::JsRegexLiteralExpression(it) => it.syntax(),
            Self::JsStringLiteralExpression(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBigintLiteralExpression(it) => it.into_syntax(),
            Self::JsBooleanLiteralExpression(it) => it.into_syntax(),
            Self::JsNullLiteralExpression(it) => it.into_syntax(),
            Self::JsNumberLiteralExpression(it) => it.into_syntax(),
            Self::JsRegexLiteralExpression(it) => it.into_syntax(),
            Self::JsStringLiteralExpression(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBigintLiteralExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsBooleanLiteralExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsNullLiteralExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsNumberLiteralExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsRegexLiteralExpression(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStringLiteralExpression(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsLiteralExpression> for SyntaxNode {
    fn from(n: AnyJsLiteralExpression) -> Self {
        match n {
            AnyJsLiteralExpression::JsBigintLiteralExpression(it) => it.into_syntax(),
            AnyJsLiteralExpression::JsBooleanLiteralExpression(it) => it.into_syntax(),
            AnyJsLiteralExpression::JsNullLiteralExpression(it) => it.into_syntax(),
            AnyJsLiteralExpression::JsNumberLiteralExpression(it) => it.into_syntax(),
            AnyJsLiteralExpression::JsRegexLiteralExpression(it) => it.into_syntax(),
            AnyJsLiteralExpression::JsStringLiteralExpression(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsLiteralExpression> for SyntaxElement {
    fn from(n: AnyJsLiteralExpression) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsDecorator> for AnyJsMethodModifier {
    fn from(node: JsDecorator) -> Self {
        Self::JsDecorator(node)
    }
}
impl From<JsStaticModifier> for AnyJsMethodModifier {
    fn from(node: JsStaticModifier) -> Self {
        Self::JsStaticModifier(node)
    }
}
impl From<TsAccessibilityModifier> for AnyJsMethodModifier {
    fn from(node: TsAccessibilityModifier) -> Self {
        Self::TsAccessibilityModifier(node)
    }
}
impl From<TsOverrideModifier> for AnyJsMethodModifier {
    fn from(node: TsOverrideModifier) -> Self {
        Self::TsOverrideModifier(node)
    }
}
impl AstNode for AnyJsMethodModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsDecorator::KIND_SET
        .union(JsStaticModifier::KIND_SET)
        .union(TsAccessibilityModifier::KIND_SET)
        .union(TsOverrideModifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_DECORATOR | JS_STATIC_MODIFIER | TS_ACCESSIBILITY_MODIFIER | TS_OVERRIDE_MODIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_DECORATOR => Self::JsDecorator(JsDecorator { syntax }),
            JS_STATIC_MODIFIER => Self::JsStaticModifier(JsStaticModifier { syntax }),
            TS_ACCESSIBILITY_MODIFIER => {
                Self::TsAccessibilityModifier(TsAccessibilityModifier { syntax })
            }
            TS_OVERRIDE_MODIFIER => Self::TsOverrideModifier(TsOverrideModifier { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsDecorator(it) => it.syntax(),
            Self::JsStaticModifier(it) => it.syntax(),
            Self::TsAccessibilityModifier(it) => it.syntax(),
            Self::TsOverrideModifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsDecorator(it) => it.into_syntax(),
            Self::JsStaticModifier(it) => it.into_syntax(),
            Self::TsAccessibilityModifier(it) => it.into_syntax(),
            Self::TsOverrideModifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsMethodModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsDecorator(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAccessibilityModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOverrideModifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsMethodModifier> for SyntaxNode {
    fn from(n: AnyJsMethodModifier) -> Self {
        match n {
            AnyJsMethodModifier::JsDecorator(it) => it.into_syntax(),
            AnyJsMethodModifier::JsStaticModifier(it) => it.into_syntax(),
            AnyJsMethodModifier::TsAccessibilityModifier(it) => it.into_syntax(),
            AnyJsMethodModifier::TsOverrideModifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsMethodModifier> for SyntaxElement {
    fn from(n: AnyJsMethodModifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsExport> for AnyJsModuleItem {
    fn from(node: JsExport) -> Self {
        Self::JsExport(node)
    }
}
impl From<JsImport> for AnyJsModuleItem {
    fn from(node: JsImport) -> Self {
        Self::JsImport(node)
    }
}
impl AstNode for AnyJsModuleItem {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsStatement::KIND_SET
        .union(JsExport::KIND_SET)
        .union(JsImport::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_EXPORT | JS_IMPORT => true,
            k if AnyJsStatement::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_EXPORT => Self::JsExport(JsExport { syntax }),
            JS_IMPORT => Self::JsImport(JsImport { syntax }),
            _ => {
                if let Some(any_js_statement) = AnyJsStatement::cast(syntax) {
                    return Some(Self::AnyJsStatement(any_js_statement));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsExport(it) => it.syntax(),
            Self::JsImport(it) => it.syntax(),
            Self::AnyJsStatement(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsExport(it) => it.into_syntax(),
            Self::JsImport(it) => it.into_syntax(),
            Self::AnyJsStatement(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsModuleItem {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExport(it) => std::fmt::Debug::fmt(it, f),
            Self::JsImport(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsModuleItem> for SyntaxNode {
    fn from(n: AnyJsModuleItem) -> Self {
        match n {
            AnyJsModuleItem::AnyJsStatement(it) => it.into_syntax(),
            AnyJsModuleItem::JsExport(it) => it.into_syntax(),
            AnyJsModuleItem::JsImport(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsModuleItem> for SyntaxElement {
    fn from(n: AnyJsModuleItem) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsMetavariable> for AnyJsModuleSource {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsModuleSource> for AnyJsModuleSource {
    fn from(node: JsModuleSource) -> Self {
        Self::JsModuleSource(node)
    }
}
impl AstNode for AnyJsModuleSource {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsMetavariable::KIND_SET.union(JsModuleSource::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_METAVARIABLE | JS_MODULE_SOURCE)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_MODULE_SOURCE => Self::JsModuleSource(JsModuleSource { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsModuleSource(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsModuleSource(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsModuleSource {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsModuleSource(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsModuleSource> for SyntaxNode {
    fn from(n: AnyJsModuleSource) -> Self {
        match n {
            AnyJsModuleSource::JsMetavariable(it) => it.into_syntax(),
            AnyJsModuleSource::JsModuleSource(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsModuleSource> for SyntaxElement {
    fn from(n: AnyJsModuleSource) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsMetavariable> for AnyJsName {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsName> for AnyJsName {
    fn from(node: JsName) -> Self {
        Self::JsName(node)
    }
}
impl From<JsPrivateName> for AnyJsName {
    fn from(node: JsPrivateName) -> Self {
        Self::JsPrivateName(node)
    }
}
impl AstNode for AnyJsName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsMetavariable::KIND_SET
        .union(JsName::KIND_SET)
        .union(JsPrivateName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_METAVARIABLE | JS_NAME | JS_PRIVATE_NAME)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_NAME => Self::JsName(JsName { syntax }),
            JS_PRIVATE_NAME => Self::JsPrivateName(JsPrivateName { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsName(it) => it.syntax(),
            Self::JsPrivateName(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsName(it) => it.into_syntax(),
            Self::JsPrivateName(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsPrivateName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsName> for SyntaxNode {
    fn from(n: AnyJsName) -> Self {
        match n {
            AnyJsName::JsMetavariable(it) => it.into_syntax(),
            AnyJsName::JsName(it) => it.into_syntax(),
            AnyJsName::JsPrivateName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsName> for SyntaxElement {
    fn from(n: AnyJsName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusNamedImportSpecifier> for AnyJsNamedImportSpecifier {
    fn from(node: JsBogusNamedImportSpecifier) -> Self {
        Self::JsBogusNamedImportSpecifier(node)
    }
}
impl From<JsNamedImportSpecifier> for AnyJsNamedImportSpecifier {
    fn from(node: JsNamedImportSpecifier) -> Self {
        Self::JsNamedImportSpecifier(node)
    }
}
impl From<JsShorthandNamedImportSpecifier> for AnyJsNamedImportSpecifier {
    fn from(node: JsShorthandNamedImportSpecifier) -> Self {
        Self::JsShorthandNamedImportSpecifier(node)
    }
}
impl AstNode for AnyJsNamedImportSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusNamedImportSpecifier::KIND_SET
        .union(JsNamedImportSpecifier::KIND_SET)
        .union(JsShorthandNamedImportSpecifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_NAMED_IMPORT_SPECIFIER
                | JS_NAMED_IMPORT_SPECIFIER
                | JS_SHORTHAND_NAMED_IMPORT_SPECIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_NAMED_IMPORT_SPECIFIER => {
                Self::JsBogusNamedImportSpecifier(JsBogusNamedImportSpecifier { syntax })
            }
            JS_NAMED_IMPORT_SPECIFIER => {
                Self::JsNamedImportSpecifier(JsNamedImportSpecifier { syntax })
            }
            JS_SHORTHAND_NAMED_IMPORT_SPECIFIER => {
                Self::JsShorthandNamedImportSpecifier(JsShorthandNamedImportSpecifier { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusNamedImportSpecifier(it) => it.syntax(),
            Self::JsNamedImportSpecifier(it) => it.syntax(),
            Self::JsShorthandNamedImportSpecifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusNamedImportSpecifier(it) => it.into_syntax(),
            Self::JsNamedImportSpecifier(it) => it.into_syntax(),
            Self::JsShorthandNamedImportSpecifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsNamedImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusNamedImportSpecifier(it) => std::fmt::Debug::fmt(it, f),
            Self::JsNamedImportSpecifier(it) => std::fmt::Debug::fmt(it, f),
            Self::JsShorthandNamedImportSpecifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsNamedImportSpecifier> for SyntaxNode {
    fn from(n: AnyJsNamedImportSpecifier) -> Self {
        match n {
            AnyJsNamedImportSpecifier::JsBogusNamedImportSpecifier(it) => it.into_syntax(),
            AnyJsNamedImportSpecifier::JsNamedImportSpecifier(it) => it.into_syntax(),
            AnyJsNamedImportSpecifier::JsShorthandNamedImportSpecifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsNamedImportSpecifier> for SyntaxElement {
    fn from(n: AnyJsNamedImportSpecifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusAssignment> for AnyJsObjectAssignmentPatternMember {
    fn from(node: JsBogusAssignment) -> Self {
        Self::JsBogusAssignment(node)
    }
}
impl From<JsObjectAssignmentPatternProperty> for AnyJsObjectAssignmentPatternMember {
    fn from(node: JsObjectAssignmentPatternProperty) -> Self {
        Self::JsObjectAssignmentPatternProperty(node)
    }
}
impl From<JsObjectAssignmentPatternRest> for AnyJsObjectAssignmentPatternMember {
    fn from(node: JsObjectAssignmentPatternRest) -> Self {
        Self::JsObjectAssignmentPatternRest(node)
    }
}
impl From<JsObjectAssignmentPatternShorthandProperty> for AnyJsObjectAssignmentPatternMember {
    fn from(node: JsObjectAssignmentPatternShorthandProperty) -> Self {
        Self::JsObjectAssignmentPatternShorthandProperty(node)
    }
}
impl AstNode for AnyJsObjectAssignmentPatternMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusAssignment::KIND_SET
        .union(JsObjectAssignmentPatternProperty::KIND_SET)
        .union(JsObjectAssignmentPatternRest::KIND_SET)
        .union(JsObjectAssignmentPatternShorthandProperty::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_ASSIGNMENT
                | JS_OBJECT_ASSIGNMENT_PATTERN_PROPERTY
                | JS_OBJECT_ASSIGNMENT_PATTERN_REST
                | JS_OBJECT_ASSIGNMENT_PATTERN_SHORTHAND_PROPERTY
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_ASSIGNMENT => Self::JsBogusAssignment(JsBogusAssignment { syntax }),
            JS_OBJECT_ASSIGNMENT_PATTERN_PROPERTY => {
                Self::JsObjectAssignmentPatternProperty(JsObjectAssignmentPatternProperty {
                    syntax,
                })
            }
            JS_OBJECT_ASSIGNMENT_PATTERN_REST => {
                Self::JsObjectAssignmentPatternRest(JsObjectAssignmentPatternRest { syntax })
            }
            JS_OBJECT_ASSIGNMENT_PATTERN_SHORTHAND_PROPERTY => {
                Self::JsObjectAssignmentPatternShorthandProperty(
                    JsObjectAssignmentPatternShorthandProperty { syntax },
                )
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusAssignment(it) => it.syntax(),
            Self::JsObjectAssignmentPatternProperty(it) => it.syntax(),
            Self::JsObjectAssignmentPatternRest(it) => it.syntax(),
            Self::JsObjectAssignmentPatternShorthandProperty(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusAssignment(it) => it.into_syntax(),
            Self::JsObjectAssignmentPatternProperty(it) => it.into_syntax(),
            Self::JsObjectAssignmentPatternRest(it) => it.into_syntax(),
            Self::JsObjectAssignmentPatternShorthandProperty(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsObjectAssignmentPatternMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusAssignment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectAssignmentPatternProperty(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectAssignmentPatternRest(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectAssignmentPatternShorthandProperty(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsObjectAssignmentPatternMember> for SyntaxNode {
    fn from(n: AnyJsObjectAssignmentPatternMember) -> Self {
        match n {
            AnyJsObjectAssignmentPatternMember::JsBogusAssignment(it) => it.into_syntax(),
            AnyJsObjectAssignmentPatternMember::JsObjectAssignmentPatternProperty(it) => {
                it.into_syntax()
            }
            AnyJsObjectAssignmentPatternMember::JsObjectAssignmentPatternRest(it) => {
                it.into_syntax()
            }
            AnyJsObjectAssignmentPatternMember::JsObjectAssignmentPatternShorthandProperty(it) => {
                it.into_syntax()
            }
        }
    }
}
impl From<AnyJsObjectAssignmentPatternMember> for SyntaxElement {
    fn from(n: AnyJsObjectAssignmentPatternMember) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusBinding> for AnyJsObjectBindingPatternMember {
    fn from(node: JsBogusBinding) -> Self {
        Self::JsBogusBinding(node)
    }
}
impl From<JsMetavariable> for AnyJsObjectBindingPatternMember {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsObjectBindingPatternProperty> for AnyJsObjectBindingPatternMember {
    fn from(node: JsObjectBindingPatternProperty) -> Self {
        Self::JsObjectBindingPatternProperty(node)
    }
}
impl From<JsObjectBindingPatternRest> for AnyJsObjectBindingPatternMember {
    fn from(node: JsObjectBindingPatternRest) -> Self {
        Self::JsObjectBindingPatternRest(node)
    }
}
impl From<JsObjectBindingPatternShorthandProperty> for AnyJsObjectBindingPatternMember {
    fn from(node: JsObjectBindingPatternShorthandProperty) -> Self {
        Self::JsObjectBindingPatternShorthandProperty(node)
    }
}
impl AstNode for AnyJsObjectBindingPatternMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusBinding::KIND_SET
        .union(JsMetavariable::KIND_SET)
        .union(JsObjectBindingPatternProperty::KIND_SET)
        .union(JsObjectBindingPatternRest::KIND_SET)
        .union(JsObjectBindingPatternShorthandProperty::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_BINDING
                | JS_METAVARIABLE
                | JS_OBJECT_BINDING_PATTERN_PROPERTY
                | JS_OBJECT_BINDING_PATTERN_REST
                | JS_OBJECT_BINDING_PATTERN_SHORTHAND_PROPERTY
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_BINDING => Self::JsBogusBinding(JsBogusBinding { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_OBJECT_BINDING_PATTERN_PROPERTY => {
                Self::JsObjectBindingPatternProperty(JsObjectBindingPatternProperty { syntax })
            }
            JS_OBJECT_BINDING_PATTERN_REST => {
                Self::JsObjectBindingPatternRest(JsObjectBindingPatternRest { syntax })
            }
            JS_OBJECT_BINDING_PATTERN_SHORTHAND_PROPERTY => {
                Self::JsObjectBindingPatternShorthandProperty(
                    JsObjectBindingPatternShorthandProperty { syntax },
                )
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusBinding(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsObjectBindingPatternProperty(it) => it.syntax(),
            Self::JsObjectBindingPatternRest(it) => it.syntax(),
            Self::JsObjectBindingPatternShorthandProperty(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusBinding(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsObjectBindingPatternProperty(it) => it.into_syntax(),
            Self::JsObjectBindingPatternRest(it) => it.into_syntax(),
            Self::JsObjectBindingPatternShorthandProperty(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsObjectBindingPatternMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusBinding(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectBindingPatternProperty(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectBindingPatternRest(it) => std::fmt::Debug::fmt(it, f),
            Self::JsObjectBindingPatternShorthandProperty(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsObjectBindingPatternMember> for SyntaxNode {
    fn from(n: AnyJsObjectBindingPatternMember) -> Self {
        match n {
            AnyJsObjectBindingPatternMember::JsBogusBinding(it) => it.into_syntax(),
            AnyJsObjectBindingPatternMember::JsMetavariable(it) => it.into_syntax(),
            AnyJsObjectBindingPatternMember::JsObjectBindingPatternProperty(it) => it.into_syntax(),
            AnyJsObjectBindingPatternMember::JsObjectBindingPatternRest(it) => it.into_syntax(),
            AnyJsObjectBindingPatternMember::JsObjectBindingPatternShorthandProperty(it) => {
                it.into_syntax()
            }
        }
    }
}
impl From<AnyJsObjectBindingPatternMember> for SyntaxElement {
    fn from(n: AnyJsObjectBindingPatternMember) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusMember> for AnyJsObjectMember {
    fn from(node: JsBogusMember) -> Self {
        Self::JsBogusMember(node)
    }
}
impl From<JsGetterObjectMember> for AnyJsObjectMember {
    fn from(node: JsGetterObjectMember) -> Self {
        Self::JsGetterObjectMember(node)
    }
}
impl From<JsMetavariable> for AnyJsObjectMember {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsMethodObjectMember> for AnyJsObjectMember {
    fn from(node: JsMethodObjectMember) -> Self {
        Self::JsMethodObjectMember(node)
    }
}
impl From<JsPropertyObjectMember> for AnyJsObjectMember {
    fn from(node: JsPropertyObjectMember) -> Self {
        Self::JsPropertyObjectMember(node)
    }
}
impl From<JsSetterObjectMember> for AnyJsObjectMember {
    fn from(node: JsSetterObjectMember) -> Self {
        Self::JsSetterObjectMember(node)
    }
}
impl From<JsShorthandPropertyObjectMember> for AnyJsObjectMember {
    fn from(node: JsShorthandPropertyObjectMember) -> Self {
        Self::JsShorthandPropertyObjectMember(node)
    }
}
impl From<JsSpread> for AnyJsObjectMember {
    fn from(node: JsSpread) -> Self {
        Self::JsSpread(node)
    }
}
impl AstNode for AnyJsObjectMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusMember::KIND_SET
        .union(JsGetterObjectMember::KIND_SET)
        .union(JsMetavariable::KIND_SET)
        .union(JsMethodObjectMember::KIND_SET)
        .union(JsPropertyObjectMember::KIND_SET)
        .union(JsSetterObjectMember::KIND_SET)
        .union(JsShorthandPropertyObjectMember::KIND_SET)
        .union(JsSpread::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_MEMBER
                | JS_GETTER_OBJECT_MEMBER
                | JS_METAVARIABLE
                | JS_METHOD_OBJECT_MEMBER
                | JS_PROPERTY_OBJECT_MEMBER
                | JS_SETTER_OBJECT_MEMBER
                | JS_SHORTHAND_PROPERTY_OBJECT_MEMBER
                | JS_SPREAD
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_MEMBER => Self::JsBogusMember(JsBogusMember { syntax }),
            JS_GETTER_OBJECT_MEMBER => Self::JsGetterObjectMember(JsGetterObjectMember { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_METHOD_OBJECT_MEMBER => Self::JsMethodObjectMember(JsMethodObjectMember { syntax }),
            JS_PROPERTY_OBJECT_MEMBER => {
                Self::JsPropertyObjectMember(JsPropertyObjectMember { syntax })
            }
            JS_SETTER_OBJECT_MEMBER => Self::JsSetterObjectMember(JsSetterObjectMember { syntax }),
            JS_SHORTHAND_PROPERTY_OBJECT_MEMBER => {
                Self::JsShorthandPropertyObjectMember(JsShorthandPropertyObjectMember { syntax })
            }
            JS_SPREAD => Self::JsSpread(JsSpread { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusMember(it) => it.syntax(),
            Self::JsGetterObjectMember(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsMethodObjectMember(it) => it.syntax(),
            Self::JsPropertyObjectMember(it) => it.syntax(),
            Self::JsSetterObjectMember(it) => it.syntax(),
            Self::JsShorthandPropertyObjectMember(it) => it.syntax(),
            Self::JsSpread(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusMember(it) => it.into_syntax(),
            Self::JsGetterObjectMember(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsMethodObjectMember(it) => it.into_syntax(),
            Self::JsPropertyObjectMember(it) => it.into_syntax(),
            Self::JsSetterObjectMember(it) => it.into_syntax(),
            Self::JsShorthandPropertyObjectMember(it) => it.into_syntax(),
            Self::JsSpread(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsGetterObjectMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMethodObjectMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsPropertyObjectMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSetterObjectMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsShorthandPropertyObjectMember(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSpread(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsObjectMember> for SyntaxNode {
    fn from(n: AnyJsObjectMember) -> Self {
        match n {
            AnyJsObjectMember::JsBogusMember(it) => it.into_syntax(),
            AnyJsObjectMember::JsGetterObjectMember(it) => it.into_syntax(),
            AnyJsObjectMember::JsMetavariable(it) => it.into_syntax(),
            AnyJsObjectMember::JsMethodObjectMember(it) => it.into_syntax(),
            AnyJsObjectMember::JsPropertyObjectMember(it) => it.into_syntax(),
            AnyJsObjectMember::JsSetterObjectMember(it) => it.into_syntax(),
            AnyJsObjectMember::JsShorthandPropertyObjectMember(it) => it.into_syntax(),
            AnyJsObjectMember::JsSpread(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsObjectMember> for SyntaxElement {
    fn from(n: AnyJsObjectMember) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsComputedMemberName> for AnyJsObjectMemberName {
    fn from(node: JsComputedMemberName) -> Self {
        Self::JsComputedMemberName(node)
    }
}
impl From<JsLiteralMemberName> for AnyJsObjectMemberName {
    fn from(node: JsLiteralMemberName) -> Self {
        Self::JsLiteralMemberName(node)
    }
}
impl From<JsMetavariable> for AnyJsObjectMemberName {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl AstNode for AnyJsObjectMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsComputedMemberName::KIND_SET
        .union(JsLiteralMemberName::KIND_SET)
        .union(JsMetavariable::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_COMPUTED_MEMBER_NAME | JS_LITERAL_MEMBER_NAME | JS_METAVARIABLE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_COMPUTED_MEMBER_NAME => Self::JsComputedMemberName(JsComputedMemberName { syntax }),
            JS_LITERAL_MEMBER_NAME => Self::JsLiteralMemberName(JsLiteralMemberName { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsComputedMemberName(it) => it.syntax(),
            Self::JsLiteralMemberName(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsComputedMemberName(it) => it.into_syntax(),
            Self::JsLiteralMemberName(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsObjectMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsComputedMemberName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsLiteralMemberName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsObjectMemberName> for SyntaxNode {
    fn from(n: AnyJsObjectMemberName) -> Self {
        match n {
            AnyJsObjectMemberName::JsComputedMemberName(it) => it.into_syntax(),
            AnyJsObjectMemberName::JsLiteralMemberName(it) => it.into_syntax(),
            AnyJsObjectMemberName::JsMetavariable(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsObjectMemberName> for SyntaxElement {
    fn from(n: AnyJsObjectMemberName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsRestParameter> for AnyJsParameter {
    fn from(node: JsRestParameter) -> Self {
        Self::JsRestParameter(node)
    }
}
impl From<TsThisParameter> for AnyJsParameter {
    fn from(node: TsThisParameter) -> Self {
        Self::TsThisParameter(node)
    }
}
impl AstNode for AnyJsParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsFormalParameter::KIND_SET
        .union(JsRestParameter::KIND_SET)
        .union(TsThisParameter::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JS_REST_PARAMETER | TS_THIS_PARAMETER => true,
            k if AnyJsFormalParameter::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_REST_PARAMETER => Self::JsRestParameter(JsRestParameter { syntax }),
            TS_THIS_PARAMETER => Self::TsThisParameter(TsThisParameter { syntax }),
            _ => {
                if let Some(any_js_formal_parameter) = AnyJsFormalParameter::cast(syntax) {
                    return Some(Self::AnyJsFormalParameter(any_js_formal_parameter));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsRestParameter(it) => it.syntax(),
            Self::TsThisParameter(it) => it.syntax(),
            Self::AnyJsFormalParameter(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsRestParameter(it) => it.into_syntax(),
            Self::TsThisParameter(it) => it.into_syntax(),
            Self::AnyJsFormalParameter(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsFormalParameter(it) => std::fmt::Debug::fmt(it, f),
            Self::JsRestParameter(it) => std::fmt::Debug::fmt(it, f),
            Self::TsThisParameter(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsParameter> for SyntaxNode {
    fn from(n: AnyJsParameter) -> Self {
        match n {
            AnyJsParameter::AnyJsFormalParameter(it) => it.into_syntax(),
            AnyJsParameter::JsRestParameter(it) => it.into_syntax(),
            AnyJsParameter::TsThisParameter(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsParameter> for SyntaxElement {
    fn from(n: AnyJsParameter) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsAccessorModifier> for AnyJsPropertyModifier {
    fn from(node: JsAccessorModifier) -> Self {
        Self::JsAccessorModifier(node)
    }
}
impl From<JsDecorator> for AnyJsPropertyModifier {
    fn from(node: JsDecorator) -> Self {
        Self::JsDecorator(node)
    }
}
impl From<JsStaticModifier> for AnyJsPropertyModifier {
    fn from(node: JsStaticModifier) -> Self {
        Self::JsStaticModifier(node)
    }
}
impl From<TsAccessibilityModifier> for AnyJsPropertyModifier {
    fn from(node: TsAccessibilityModifier) -> Self {
        Self::TsAccessibilityModifier(node)
    }
}
impl From<TsOverrideModifier> for AnyJsPropertyModifier {
    fn from(node: TsOverrideModifier) -> Self {
        Self::TsOverrideModifier(node)
    }
}
impl From<TsReadonlyModifier> for AnyJsPropertyModifier {
    fn from(node: TsReadonlyModifier) -> Self {
        Self::TsReadonlyModifier(node)
    }
}
impl AstNode for AnyJsPropertyModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsAccessorModifier::KIND_SET
        .union(JsDecorator::KIND_SET)
        .union(JsStaticModifier::KIND_SET)
        .union(TsAccessibilityModifier::KIND_SET)
        .union(TsOverrideModifier::KIND_SET)
        .union(TsReadonlyModifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_ACCESSOR_MODIFIER
                | JS_DECORATOR
                | JS_STATIC_MODIFIER
                | TS_ACCESSIBILITY_MODIFIER
                | TS_OVERRIDE_MODIFIER
                | TS_READONLY_MODIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ACCESSOR_MODIFIER => Self::JsAccessorModifier(JsAccessorModifier { syntax }),
            JS_DECORATOR => Self::JsDecorator(JsDecorator { syntax }),
            JS_STATIC_MODIFIER => Self::JsStaticModifier(JsStaticModifier { syntax }),
            TS_ACCESSIBILITY_MODIFIER => {
                Self::TsAccessibilityModifier(TsAccessibilityModifier { syntax })
            }
            TS_OVERRIDE_MODIFIER => Self::TsOverrideModifier(TsOverrideModifier { syntax }),
            TS_READONLY_MODIFIER => Self::TsReadonlyModifier(TsReadonlyModifier { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsAccessorModifier(it) => it.syntax(),
            Self::JsDecorator(it) => it.syntax(),
            Self::JsStaticModifier(it) => it.syntax(),
            Self::TsAccessibilityModifier(it) => it.syntax(),
            Self::TsOverrideModifier(it) => it.syntax(),
            Self::TsReadonlyModifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsAccessorModifier(it) => it.into_syntax(),
            Self::JsDecorator(it) => it.into_syntax(),
            Self::JsStaticModifier(it) => it.into_syntax(),
            Self::TsAccessibilityModifier(it) => it.into_syntax(),
            Self::TsOverrideModifier(it) => it.into_syntax(),
            Self::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsPropertyModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsAccessorModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::JsDecorator(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAccessibilityModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOverrideModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsReadonlyModifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsPropertyModifier> for SyntaxNode {
    fn from(n: AnyJsPropertyModifier) -> Self {
        match n {
            AnyJsPropertyModifier::JsAccessorModifier(it) => it.into_syntax(),
            AnyJsPropertyModifier::JsDecorator(it) => it.into_syntax(),
            AnyJsPropertyModifier::JsStaticModifier(it) => it.into_syntax(),
            AnyJsPropertyModifier::TsAccessibilityModifier(it) => it.into_syntax(),
            AnyJsPropertyModifier::TsOverrideModifier(it) => it.into_syntax(),
            AnyJsPropertyModifier::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsPropertyModifier> for SyntaxElement {
    fn from(n: AnyJsPropertyModifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsExpressionSnipped> for AnyJsRoot {
    fn from(node: JsExpressionSnipped) -> Self {
        Self::JsExpressionSnipped(node)
    }
}
impl From<JsModule> for AnyJsRoot {
    fn from(node: JsModule) -> Self {
        Self::JsModule(node)
    }
}
impl From<JsScript> for AnyJsRoot {
    fn from(node: JsScript) -> Self {
        Self::JsScript(node)
    }
}
impl From<TsDeclarationModule> for AnyJsRoot {
    fn from(node: TsDeclarationModule) -> Self {
        Self::TsDeclarationModule(node)
    }
}
impl AstNode for AnyJsRoot {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsExpressionSnipped::KIND_SET
        .union(JsModule::KIND_SET)
        .union(JsScript::KIND_SET)
        .union(TsDeclarationModule::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_EXPRESSION_SNIPPED | JS_MODULE | JS_SCRIPT | TS_DECLARATION_MODULE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_EXPRESSION_SNIPPED => Self::JsExpressionSnipped(JsExpressionSnipped { syntax }),
            JS_MODULE => Self::JsModule(JsModule { syntax }),
            JS_SCRIPT => Self::JsScript(JsScript { syntax }),
            TS_DECLARATION_MODULE => Self::TsDeclarationModule(TsDeclarationModule { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsExpressionSnipped(it) => it.syntax(),
            Self::JsModule(it) => it.syntax(),
            Self::JsScript(it) => it.syntax(),
            Self::TsDeclarationModule(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsExpressionSnipped(it) => it.into_syntax(),
            Self::JsModule(it) => it.into_syntax(),
            Self::JsScript(it) => it.into_syntax(),
            Self::TsDeclarationModule(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsRoot {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsExpressionSnipped(it) => std::fmt::Debug::fmt(it, f),
            Self::JsModule(it) => std::fmt::Debug::fmt(it, f),
            Self::JsScript(it) => std::fmt::Debug::fmt(it, f),
            Self::TsDeclarationModule(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsRoot> for SyntaxNode {
    fn from(n: AnyJsRoot) -> Self {
        match n {
            AnyJsRoot::JsExpressionSnipped(it) => it.into_syntax(),
            AnyJsRoot::JsModule(it) => it.into_syntax(),
            AnyJsRoot::JsScript(it) => it.into_syntax(),
            AnyJsRoot::TsDeclarationModule(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsRoot> for SyntaxElement {
    fn from(n: AnyJsRoot) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBlockStatement> for AnyJsStatement {
    fn from(node: JsBlockStatement) -> Self {
        Self::JsBlockStatement(node)
    }
}
impl From<JsBogusStatement> for AnyJsStatement {
    fn from(node: JsBogusStatement) -> Self {
        Self::JsBogusStatement(node)
    }
}
impl From<JsBreakStatement> for AnyJsStatement {
    fn from(node: JsBreakStatement) -> Self {
        Self::JsBreakStatement(node)
    }
}
impl From<JsClassDeclaration> for AnyJsStatement {
    fn from(node: JsClassDeclaration) -> Self {
        Self::JsClassDeclaration(node)
    }
}
impl From<JsContinueStatement> for AnyJsStatement {
    fn from(node: JsContinueStatement) -> Self {
        Self::JsContinueStatement(node)
    }
}
impl From<JsDebuggerStatement> for AnyJsStatement {
    fn from(node: JsDebuggerStatement) -> Self {
        Self::JsDebuggerStatement(node)
    }
}
impl From<JsDoWhileStatement> for AnyJsStatement {
    fn from(node: JsDoWhileStatement) -> Self {
        Self::JsDoWhileStatement(node)
    }
}
impl From<JsEmptyStatement> for AnyJsStatement {
    fn from(node: JsEmptyStatement) -> Self {
        Self::JsEmptyStatement(node)
    }
}
impl From<JsExpressionStatement> for AnyJsStatement {
    fn from(node: JsExpressionStatement) -> Self {
        Self::JsExpressionStatement(node)
    }
}
impl From<JsForInStatement> for AnyJsStatement {
    fn from(node: JsForInStatement) -> Self {
        Self::JsForInStatement(node)
    }
}
impl From<JsForOfStatement> for AnyJsStatement {
    fn from(node: JsForOfStatement) -> Self {
        Self::JsForOfStatement(node)
    }
}
impl From<JsForStatement> for AnyJsStatement {
    fn from(node: JsForStatement) -> Self {
        Self::JsForStatement(node)
    }
}
impl From<JsFunctionDeclaration> for AnyJsStatement {
    fn from(node: JsFunctionDeclaration) -> Self {
        Self::JsFunctionDeclaration(node)
    }
}
impl From<JsIfStatement> for AnyJsStatement {
    fn from(node: JsIfStatement) -> Self {
        Self::JsIfStatement(node)
    }
}
impl From<JsLabeledStatement> for AnyJsStatement {
    fn from(node: JsLabeledStatement) -> Self {
        Self::JsLabeledStatement(node)
    }
}
impl From<JsMetavariable> for AnyJsStatement {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsReturnStatement> for AnyJsStatement {
    fn from(node: JsReturnStatement) -> Self {
        Self::JsReturnStatement(node)
    }
}
impl From<JsSwitchStatement> for AnyJsStatement {
    fn from(node: JsSwitchStatement) -> Self {
        Self::JsSwitchStatement(node)
    }
}
impl From<JsThrowStatement> for AnyJsStatement {
    fn from(node: JsThrowStatement) -> Self {
        Self::JsThrowStatement(node)
    }
}
impl From<JsTryFinallyStatement> for AnyJsStatement {
    fn from(node: JsTryFinallyStatement) -> Self {
        Self::JsTryFinallyStatement(node)
    }
}
impl From<JsTryStatement> for AnyJsStatement {
    fn from(node: JsTryStatement) -> Self {
        Self::JsTryStatement(node)
    }
}
impl From<JsVariableStatement> for AnyJsStatement {
    fn from(node: JsVariableStatement) -> Self {
        Self::JsVariableStatement(node)
    }
}
impl From<JsWhileStatement> for AnyJsStatement {
    fn from(node: JsWhileStatement) -> Self {
        Self::JsWhileStatement(node)
    }
}
impl From<JsWithStatement> for AnyJsStatement {
    fn from(node: JsWithStatement) -> Self {
        Self::JsWithStatement(node)
    }
}
impl From<TsDeclareFunctionDeclaration> for AnyJsStatement {
    fn from(node: TsDeclareFunctionDeclaration) -> Self {
        Self::TsDeclareFunctionDeclaration(node)
    }
}
impl From<TsDeclareStatement> for AnyJsStatement {
    fn from(node: TsDeclareStatement) -> Self {
        Self::TsDeclareStatement(node)
    }
}
impl From<TsEnumDeclaration> for AnyJsStatement {
    fn from(node: TsEnumDeclaration) -> Self {
        Self::TsEnumDeclaration(node)
    }
}
impl From<TsExternalModuleDeclaration> for AnyJsStatement {
    fn from(node: TsExternalModuleDeclaration) -> Self {
        Self::TsExternalModuleDeclaration(node)
    }
}
impl From<TsGlobalDeclaration> for AnyJsStatement {
    fn from(node: TsGlobalDeclaration) -> Self {
        Self::TsGlobalDeclaration(node)
    }
}
impl From<TsImportEqualsDeclaration> for AnyJsStatement {
    fn from(node: TsImportEqualsDeclaration) -> Self {
        Self::TsImportEqualsDeclaration(node)
    }
}
impl From<TsInterfaceDeclaration> for AnyJsStatement {
    fn from(node: TsInterfaceDeclaration) -> Self {
        Self::TsInterfaceDeclaration(node)
    }
}
impl From<TsModuleDeclaration> for AnyJsStatement {
    fn from(node: TsModuleDeclaration) -> Self {
        Self::TsModuleDeclaration(node)
    }
}
impl From<TsTypeAliasDeclaration> for AnyJsStatement {
    fn from(node: TsTypeAliasDeclaration) -> Self {
        Self::TsTypeAliasDeclaration(node)
    }
}
impl AstNode for AnyJsStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBlockStatement::KIND_SET
        .union(JsBogusStatement::KIND_SET)
        .union(JsBreakStatement::KIND_SET)
        .union(JsClassDeclaration::KIND_SET)
        .union(JsContinueStatement::KIND_SET)
        .union(JsDebuggerStatement::KIND_SET)
        .union(JsDoWhileStatement::KIND_SET)
        .union(JsEmptyStatement::KIND_SET)
        .union(JsExpressionStatement::KIND_SET)
        .union(JsForInStatement::KIND_SET)
        .union(JsForOfStatement::KIND_SET)
        .union(JsForStatement::KIND_SET)
        .union(JsFunctionDeclaration::KIND_SET)
        .union(JsIfStatement::KIND_SET)
        .union(JsLabeledStatement::KIND_SET)
        .union(JsMetavariable::KIND_SET)
        .union(JsReturnStatement::KIND_SET)
        .union(JsSwitchStatement::KIND_SET)
        .union(JsThrowStatement::KIND_SET)
        .union(JsTryFinallyStatement::KIND_SET)
        .union(JsTryStatement::KIND_SET)
        .union(JsVariableStatement::KIND_SET)
        .union(JsWhileStatement::KIND_SET)
        .union(JsWithStatement::KIND_SET)
        .union(TsDeclareFunctionDeclaration::KIND_SET)
        .union(TsDeclareStatement::KIND_SET)
        .union(TsEnumDeclaration::KIND_SET)
        .union(TsExternalModuleDeclaration::KIND_SET)
        .union(TsGlobalDeclaration::KIND_SET)
        .union(TsImportEqualsDeclaration::KIND_SET)
        .union(TsInterfaceDeclaration::KIND_SET)
        .union(TsModuleDeclaration::KIND_SET)
        .union(TsTypeAliasDeclaration::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BLOCK_STATEMENT
                | JS_BOGUS_STATEMENT
                | JS_BREAK_STATEMENT
                | JS_CLASS_DECLARATION
                | JS_CONTINUE_STATEMENT
                | JS_DEBUGGER_STATEMENT
                | JS_DO_WHILE_STATEMENT
                | JS_EMPTY_STATEMENT
                | JS_EXPRESSION_STATEMENT
                | JS_FOR_IN_STATEMENT
                | JS_FOR_OF_STATEMENT
                | JS_FOR_STATEMENT
                | JS_FUNCTION_DECLARATION
                | JS_IF_STATEMENT
                | JS_LABELED_STATEMENT
                | JS_METAVARIABLE
                | JS_RETURN_STATEMENT
                | JS_SWITCH_STATEMENT
                | JS_THROW_STATEMENT
                | JS_TRY_FINALLY_STATEMENT
                | JS_TRY_STATEMENT
                | JS_VARIABLE_STATEMENT
                | JS_WHILE_STATEMENT
                | JS_WITH_STATEMENT
                | TS_DECLARE_FUNCTION_DECLARATION
                | TS_DECLARE_STATEMENT
                | TS_ENUM_DECLARATION
                | TS_EXTERNAL_MODULE_DECLARATION
                | TS_GLOBAL_DECLARATION
                | TS_IMPORT_EQUALS_DECLARATION
                | TS_INTERFACE_DECLARATION
                | TS_MODULE_DECLARATION
                | TS_TYPE_ALIAS_DECLARATION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BLOCK_STATEMENT => Self::JsBlockStatement(JsBlockStatement { syntax }),
            JS_BOGUS_STATEMENT => Self::JsBogusStatement(JsBogusStatement { syntax }),
            JS_BREAK_STATEMENT => Self::JsBreakStatement(JsBreakStatement { syntax }),
            JS_CLASS_DECLARATION => Self::JsClassDeclaration(JsClassDeclaration { syntax }),
            JS_CONTINUE_STATEMENT => Self::JsContinueStatement(JsContinueStatement { syntax }),
            JS_DEBUGGER_STATEMENT => Self::JsDebuggerStatement(JsDebuggerStatement { syntax }),
            JS_DO_WHILE_STATEMENT => Self::JsDoWhileStatement(JsDoWhileStatement { syntax }),
            JS_EMPTY_STATEMENT => Self::JsEmptyStatement(JsEmptyStatement { syntax }),
            JS_EXPRESSION_STATEMENT => {
                Self::JsExpressionStatement(JsExpressionStatement { syntax })
            }
            JS_FOR_IN_STATEMENT => Self::JsForInStatement(JsForInStatement { syntax }),
            JS_FOR_OF_STATEMENT => Self::JsForOfStatement(JsForOfStatement { syntax }),
            JS_FOR_STATEMENT => Self::JsForStatement(JsForStatement { syntax }),
            JS_FUNCTION_DECLARATION => {
                Self::JsFunctionDeclaration(JsFunctionDeclaration { syntax })
            }
            JS_IF_STATEMENT => Self::JsIfStatement(JsIfStatement { syntax }),
            JS_LABELED_STATEMENT => Self::JsLabeledStatement(JsLabeledStatement { syntax }),
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JS_RETURN_STATEMENT => Self::JsReturnStatement(JsReturnStatement { syntax }),
            JS_SWITCH_STATEMENT => Self::JsSwitchStatement(JsSwitchStatement { syntax }),
            JS_THROW_STATEMENT => Self::JsThrowStatement(JsThrowStatement { syntax }),
            JS_TRY_FINALLY_STATEMENT => {
                Self::JsTryFinallyStatement(JsTryFinallyStatement { syntax })
            }
            JS_TRY_STATEMENT => Self::JsTryStatement(JsTryStatement { syntax }),
            JS_VARIABLE_STATEMENT => Self::JsVariableStatement(JsVariableStatement { syntax }),
            JS_WHILE_STATEMENT => Self::JsWhileStatement(JsWhileStatement { syntax }),
            JS_WITH_STATEMENT => Self::JsWithStatement(JsWithStatement { syntax }),
            TS_DECLARE_FUNCTION_DECLARATION => {
                Self::TsDeclareFunctionDeclaration(TsDeclareFunctionDeclaration { syntax })
            }
            TS_DECLARE_STATEMENT => Self::TsDeclareStatement(TsDeclareStatement { syntax }),
            TS_ENUM_DECLARATION => Self::TsEnumDeclaration(TsEnumDeclaration { syntax }),
            TS_EXTERNAL_MODULE_DECLARATION => {
                Self::TsExternalModuleDeclaration(TsExternalModuleDeclaration { syntax })
            }
            TS_GLOBAL_DECLARATION => Self::TsGlobalDeclaration(TsGlobalDeclaration { syntax }),
            TS_IMPORT_EQUALS_DECLARATION => {
                Self::TsImportEqualsDeclaration(TsImportEqualsDeclaration { syntax })
            }
            TS_INTERFACE_DECLARATION => {
                Self::TsInterfaceDeclaration(TsInterfaceDeclaration { syntax })
            }
            TS_MODULE_DECLARATION => Self::TsModuleDeclaration(TsModuleDeclaration { syntax }),
            TS_TYPE_ALIAS_DECLARATION => {
                Self::TsTypeAliasDeclaration(TsTypeAliasDeclaration { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBlockStatement(it) => it.syntax(),
            Self::JsBogusStatement(it) => it.syntax(),
            Self::JsBreakStatement(it) => it.syntax(),
            Self::JsClassDeclaration(it) => it.syntax(),
            Self::JsContinueStatement(it) => it.syntax(),
            Self::JsDebuggerStatement(it) => it.syntax(),
            Self::JsDoWhileStatement(it) => it.syntax(),
            Self::JsEmptyStatement(it) => it.syntax(),
            Self::JsExpressionStatement(it) => it.syntax(),
            Self::JsForInStatement(it) => it.syntax(),
            Self::JsForOfStatement(it) => it.syntax(),
            Self::JsForStatement(it) => it.syntax(),
            Self::JsFunctionDeclaration(it) => it.syntax(),
            Self::JsIfStatement(it) => it.syntax(),
            Self::JsLabeledStatement(it) => it.syntax(),
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsReturnStatement(it) => it.syntax(),
            Self::JsSwitchStatement(it) => it.syntax(),
            Self::JsThrowStatement(it) => it.syntax(),
            Self::JsTryFinallyStatement(it) => it.syntax(),
            Self::JsTryStatement(it) => it.syntax(),
            Self::JsVariableStatement(it) => it.syntax(),
            Self::JsWhileStatement(it) => it.syntax(),
            Self::JsWithStatement(it) => it.syntax(),
            Self::TsDeclareFunctionDeclaration(it) => it.syntax(),
            Self::TsDeclareStatement(it) => it.syntax(),
            Self::TsEnumDeclaration(it) => it.syntax(),
            Self::TsExternalModuleDeclaration(it) => it.syntax(),
            Self::TsGlobalDeclaration(it) => it.syntax(),
            Self::TsImportEqualsDeclaration(it) => it.syntax(),
            Self::TsInterfaceDeclaration(it) => it.syntax(),
            Self::TsModuleDeclaration(it) => it.syntax(),
            Self::TsTypeAliasDeclaration(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBlockStatement(it) => it.into_syntax(),
            Self::JsBogusStatement(it) => it.into_syntax(),
            Self::JsBreakStatement(it) => it.into_syntax(),
            Self::JsClassDeclaration(it) => it.into_syntax(),
            Self::JsContinueStatement(it) => it.into_syntax(),
            Self::JsDebuggerStatement(it) => it.into_syntax(),
            Self::JsDoWhileStatement(it) => it.into_syntax(),
            Self::JsEmptyStatement(it) => it.into_syntax(),
            Self::JsExpressionStatement(it) => it.into_syntax(),
            Self::JsForInStatement(it) => it.into_syntax(),
            Self::JsForOfStatement(it) => it.into_syntax(),
            Self::JsForStatement(it) => it.into_syntax(),
            Self::JsFunctionDeclaration(it) => it.into_syntax(),
            Self::JsIfStatement(it) => it.into_syntax(),
            Self::JsLabeledStatement(it) => it.into_syntax(),
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsReturnStatement(it) => it.into_syntax(),
            Self::JsSwitchStatement(it) => it.into_syntax(),
            Self::JsThrowStatement(it) => it.into_syntax(),
            Self::JsTryFinallyStatement(it) => it.into_syntax(),
            Self::JsTryStatement(it) => it.into_syntax(),
            Self::JsVariableStatement(it) => it.into_syntax(),
            Self::JsWhileStatement(it) => it.into_syntax(),
            Self::JsWithStatement(it) => it.into_syntax(),
            Self::TsDeclareFunctionDeclaration(it) => it.into_syntax(),
            Self::TsDeclareStatement(it) => it.into_syntax(),
            Self::TsEnumDeclaration(it) => it.into_syntax(),
            Self::TsExternalModuleDeclaration(it) => it.into_syntax(),
            Self::TsGlobalDeclaration(it) => it.into_syntax(),
            Self::TsImportEqualsDeclaration(it) => it.into_syntax(),
            Self::TsInterfaceDeclaration(it) => it.into_syntax(),
            Self::TsModuleDeclaration(it) => it.into_syntax(),
            Self::TsTypeAliasDeclaration(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBlockStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsBogusStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsBreakStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsClassDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsContinueStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsDebuggerStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsDoWhileStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsEmptyStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsExpressionStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsForInStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsForOfStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsForStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsFunctionDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::JsIfStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsLabeledStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsReturnStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsSwitchStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsThrowStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsTryFinallyStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsTryStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsVariableStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsWhileStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsWithStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::TsDeclareFunctionDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsDeclareStatement(it) => std::fmt::Debug::fmt(it, f),
            Self::TsEnumDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsExternalModuleDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsGlobalDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsImportEqualsDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInterfaceDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsModuleDeclaration(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAliasDeclaration(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsStatement> for SyntaxNode {
    fn from(n: AnyJsStatement) -> Self {
        match n {
            AnyJsStatement::JsBlockStatement(it) => it.into_syntax(),
            AnyJsStatement::JsBogusStatement(it) => it.into_syntax(),
            AnyJsStatement::JsBreakStatement(it) => it.into_syntax(),
            AnyJsStatement::JsClassDeclaration(it) => it.into_syntax(),
            AnyJsStatement::JsContinueStatement(it) => it.into_syntax(),
            AnyJsStatement::JsDebuggerStatement(it) => it.into_syntax(),
            AnyJsStatement::JsDoWhileStatement(it) => it.into_syntax(),
            AnyJsStatement::JsEmptyStatement(it) => it.into_syntax(),
            AnyJsStatement::JsExpressionStatement(it) => it.into_syntax(),
            AnyJsStatement::JsForInStatement(it) => it.into_syntax(),
            AnyJsStatement::JsForOfStatement(it) => it.into_syntax(),
            AnyJsStatement::JsForStatement(it) => it.into_syntax(),
            AnyJsStatement::JsFunctionDeclaration(it) => it.into_syntax(),
            AnyJsStatement::JsIfStatement(it) => it.into_syntax(),
            AnyJsStatement::JsLabeledStatement(it) => it.into_syntax(),
            AnyJsStatement::JsMetavariable(it) => it.into_syntax(),
            AnyJsStatement::JsReturnStatement(it) => it.into_syntax(),
            AnyJsStatement::JsSwitchStatement(it) => it.into_syntax(),
            AnyJsStatement::JsThrowStatement(it) => it.into_syntax(),
            AnyJsStatement::JsTryFinallyStatement(it) => it.into_syntax(),
            AnyJsStatement::JsTryStatement(it) => it.into_syntax(),
            AnyJsStatement::JsVariableStatement(it) => it.into_syntax(),
            AnyJsStatement::JsWhileStatement(it) => it.into_syntax(),
            AnyJsStatement::JsWithStatement(it) => it.into_syntax(),
            AnyJsStatement::TsDeclareFunctionDeclaration(it) => it.into_syntax(),
            AnyJsStatement::TsDeclareStatement(it) => it.into_syntax(),
            AnyJsStatement::TsEnumDeclaration(it) => it.into_syntax(),
            AnyJsStatement::TsExternalModuleDeclaration(it) => it.into_syntax(),
            AnyJsStatement::TsGlobalDeclaration(it) => it.into_syntax(),
            AnyJsStatement::TsImportEqualsDeclaration(it) => it.into_syntax(),
            AnyJsStatement::TsInterfaceDeclaration(it) => it.into_syntax(),
            AnyJsStatement::TsModuleDeclaration(it) => it.into_syntax(),
            AnyJsStatement::TsTypeAliasDeclaration(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsStatement> for SyntaxElement {
    fn from(n: AnyJsStatement) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsCaseClause> for AnyJsSwitchClause {
    fn from(node: JsCaseClause) -> Self {
        Self::JsCaseClause(node)
    }
}
impl From<JsDefaultClause> for AnyJsSwitchClause {
    fn from(node: JsDefaultClause) -> Self {
        Self::JsDefaultClause(node)
    }
}
impl AstNode for AnyJsSwitchClause {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsCaseClause::KIND_SET.union(JsDefaultClause::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_CASE_CLAUSE | JS_DEFAULT_CLAUSE)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_CASE_CLAUSE => Self::JsCaseClause(JsCaseClause { syntax }),
            JS_DEFAULT_CLAUSE => Self::JsDefaultClause(JsDefaultClause { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsCaseClause(it) => it.syntax(),
            Self::JsDefaultClause(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsCaseClause(it) => it.into_syntax(),
            Self::JsDefaultClause(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsSwitchClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsCaseClause(it) => std::fmt::Debug::fmt(it, f),
            Self::JsDefaultClause(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsSwitchClause> for SyntaxNode {
    fn from(n: AnyJsSwitchClause) -> Self {
        match n {
            AnyJsSwitchClause::JsCaseClause(it) => it.into_syntax(),
            AnyJsSwitchClause::JsDefaultClause(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsSwitchClause> for SyntaxElement {
    fn from(n: AnyJsSwitchClause) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsTemplateChunkElement> for AnyJsTemplateElement {
    fn from(node: JsTemplateChunkElement) -> Self {
        Self::JsTemplateChunkElement(node)
    }
}
impl From<JsTemplateElement> for AnyJsTemplateElement {
    fn from(node: JsTemplateElement) -> Self {
        Self::JsTemplateElement(node)
    }
}
impl AstNode for AnyJsTemplateElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsTemplateChunkElement::KIND_SET.union(JsTemplateElement::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_TEMPLATE_CHUNK_ELEMENT | JS_TEMPLATE_ELEMENT)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_TEMPLATE_CHUNK_ELEMENT => {
                Self::JsTemplateChunkElement(JsTemplateChunkElement { syntax })
            }
            JS_TEMPLATE_ELEMENT => Self::JsTemplateElement(JsTemplateElement { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsTemplateChunkElement(it) => it.syntax(),
            Self::JsTemplateElement(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsTemplateChunkElement(it) => it.into_syntax(),
            Self::JsTemplateElement(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsTemplateChunkElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsTemplateElement(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsTemplateElement> for SyntaxNode {
    fn from(n: AnyJsTemplateElement) -> Self {
        match n {
            AnyJsTemplateElement::JsTemplateChunkElement(it) => it.into_syntax(),
            AnyJsTemplateElement::JsTemplateElement(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsTemplateElement> for SyntaxElement {
    fn from(n: AnyJsTemplateElement) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsMetavariable> for AnyJsxAttribute {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsxAttribute> for AnyJsxAttribute {
    fn from(node: JsxAttribute) -> Self {
        Self::JsxAttribute(node)
    }
}
impl From<JsxSpreadAttribute> for AnyJsxAttribute {
    fn from(node: JsxSpreadAttribute) -> Self {
        Self::JsxSpreadAttribute(node)
    }
}
impl AstNode for AnyJsxAttribute {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsMetavariable::KIND_SET
        .union(JsxAttribute::KIND_SET)
        .union(JsxSpreadAttribute::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_METAVARIABLE | JSX_ATTRIBUTE | JSX_SPREAD_ATTRIBUTE)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JSX_ATTRIBUTE => Self::JsxAttribute(JsxAttribute { syntax }),
            JSX_SPREAD_ATTRIBUTE => Self::JsxSpreadAttribute(JsxSpreadAttribute { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsxAttribute(it) => it.syntax(),
            Self::JsxSpreadAttribute(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsxAttribute(it) => it.into_syntax(),
            Self::JsxSpreadAttribute(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxAttribute {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxAttribute(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxSpreadAttribute(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxAttribute> for SyntaxNode {
    fn from(n: AnyJsxAttribute) -> Self {
        match n {
            AnyJsxAttribute::JsMetavariable(it) => it.into_syntax(),
            AnyJsxAttribute::JsxAttribute(it) => it.into_syntax(),
            AnyJsxAttribute::JsxSpreadAttribute(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxAttribute> for SyntaxElement {
    fn from(n: AnyJsxAttribute) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsxName> for AnyJsxAttributeName {
    fn from(node: JsxName) -> Self {
        Self::JsxName(node)
    }
}
impl From<JsxNamespaceName> for AnyJsxAttributeName {
    fn from(node: JsxNamespaceName) -> Self {
        Self::JsxNamespaceName(node)
    }
}
impl AstNode for AnyJsxAttributeName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsxName::KIND_SET.union(JsxNamespaceName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JSX_NAME | JSX_NAMESPACE_NAME)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JSX_NAME => Self::JsxName(JsxName { syntax }),
            JSX_NAMESPACE_NAME => Self::JsxNamespaceName(JsxNamespaceName { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsxName(it) => it.syntax(),
            Self::JsxNamespaceName(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsxName(it) => it.into_syntax(),
            Self::JsxNamespaceName(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxAttributeName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsxName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxNamespaceName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxAttributeName> for SyntaxNode {
    fn from(n: AnyJsxAttributeName) -> Self {
        match n {
            AnyJsxAttributeName::JsxName(it) => it.into_syntax(),
            AnyJsxAttributeName::JsxNamespaceName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxAttributeName> for SyntaxElement {
    fn from(n: AnyJsxAttributeName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsxExpressionAttributeValue> for AnyJsxAttributeValue {
    fn from(node: JsxExpressionAttributeValue) -> Self {
        Self::JsxExpressionAttributeValue(node)
    }
}
impl From<JsxString> for AnyJsxAttributeValue {
    fn from(node: JsxString) -> Self {
        Self::JsxString(node)
    }
}
impl AstNode for AnyJsxAttributeValue {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyJsxTag::KIND_SET
        .union(JsxExpressionAttributeValue::KIND_SET)
        .union(JsxString::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            JSX_EXPRESSION_ATTRIBUTE_VALUE | JSX_STRING => true,
            k if AnyJsxTag::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JSX_EXPRESSION_ATTRIBUTE_VALUE => {
                Self::JsxExpressionAttributeValue(JsxExpressionAttributeValue { syntax })
            }
            JSX_STRING => Self::JsxString(JsxString { syntax }),
            _ => {
                if let Some(any_jsx_tag) = AnyJsxTag::cast(syntax) {
                    return Some(Self::AnyJsxTag(any_jsx_tag));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsxExpressionAttributeValue(it) => it.syntax(),
            Self::JsxString(it) => it.syntax(),
            Self::AnyJsxTag(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsxExpressionAttributeValue(it) => it.into_syntax(),
            Self::JsxString(it) => it.into_syntax(),
            Self::AnyJsxTag(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxAttributeValue {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyJsxTag(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxExpressionAttributeValue(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxString(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxAttributeValue> for SyntaxNode {
    fn from(n: AnyJsxAttributeValue) -> Self {
        match n {
            AnyJsxAttributeValue::AnyJsxTag(it) => it.into_syntax(),
            AnyJsxAttributeValue::JsxExpressionAttributeValue(it) => it.into_syntax(),
            AnyJsxAttributeValue::JsxString(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxAttributeValue> for SyntaxElement {
    fn from(n: AnyJsxAttributeValue) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsMetavariable> for AnyJsxChild {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsxElement> for AnyJsxChild {
    fn from(node: JsxElement) -> Self {
        Self::JsxElement(node)
    }
}
impl From<JsxExpressionChild> for AnyJsxChild {
    fn from(node: JsxExpressionChild) -> Self {
        Self::JsxExpressionChild(node)
    }
}
impl From<JsxFragment> for AnyJsxChild {
    fn from(node: JsxFragment) -> Self {
        Self::JsxFragment(node)
    }
}
impl From<JsxSelfClosingElement> for AnyJsxChild {
    fn from(node: JsxSelfClosingElement) -> Self {
        Self::JsxSelfClosingElement(node)
    }
}
impl From<JsxSpreadChild> for AnyJsxChild {
    fn from(node: JsxSpreadChild) -> Self {
        Self::JsxSpreadChild(node)
    }
}
impl From<JsxText> for AnyJsxChild {
    fn from(node: JsxText) -> Self {
        Self::JsxText(node)
    }
}
impl AstNode for AnyJsxChild {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsMetavariable::KIND_SET
        .union(JsxElement::KIND_SET)
        .union(JsxExpressionChild::KIND_SET)
        .union(JsxFragment::KIND_SET)
        .union(JsxSelfClosingElement::KIND_SET)
        .union(JsxSpreadChild::KIND_SET)
        .union(JsxText::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_METAVARIABLE
                | JSX_ELEMENT
                | JSX_EXPRESSION_CHILD
                | JSX_FRAGMENT
                | JSX_SELF_CLOSING_ELEMENT
                | JSX_SPREAD_CHILD
                | JSX_TEXT
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JSX_ELEMENT => Self::JsxElement(JsxElement { syntax }),
            JSX_EXPRESSION_CHILD => Self::JsxExpressionChild(JsxExpressionChild { syntax }),
            JSX_FRAGMENT => Self::JsxFragment(JsxFragment { syntax }),
            JSX_SELF_CLOSING_ELEMENT => {
                Self::JsxSelfClosingElement(JsxSelfClosingElement { syntax })
            }
            JSX_SPREAD_CHILD => Self::JsxSpreadChild(JsxSpreadChild { syntax }),
            JSX_TEXT => Self::JsxText(JsxText { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsxElement(it) => it.syntax(),
            Self::JsxExpressionChild(it) => it.syntax(),
            Self::JsxFragment(it) => it.syntax(),
            Self::JsxSelfClosingElement(it) => it.syntax(),
            Self::JsxSpreadChild(it) => it.syntax(),
            Self::JsxText(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsxElement(it) => it.into_syntax(),
            Self::JsxExpressionChild(it) => it.into_syntax(),
            Self::JsxFragment(it) => it.into_syntax(),
            Self::JsxSelfClosingElement(it) => it.into_syntax(),
            Self::JsxSpreadChild(it) => it.into_syntax(),
            Self::JsxText(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxChild {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxExpressionChild(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxFragment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxSelfClosingElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxSpreadChild(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxText(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxChild> for SyntaxNode {
    fn from(n: AnyJsxChild) -> Self {
        match n {
            AnyJsxChild::JsMetavariable(it) => it.into_syntax(),
            AnyJsxChild::JsxElement(it) => it.into_syntax(),
            AnyJsxChild::JsxExpressionChild(it) => it.into_syntax(),
            AnyJsxChild::JsxFragment(it) => it.into_syntax(),
            AnyJsxChild::JsxSelfClosingElement(it) => it.into_syntax(),
            AnyJsxChild::JsxSpreadChild(it) => it.into_syntax(),
            AnyJsxChild::JsxText(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxChild> for SyntaxElement {
    fn from(n: AnyJsxChild) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsMetavariable> for AnyJsxElementName {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<JsxMemberName> for AnyJsxElementName {
    fn from(node: JsxMemberName) -> Self {
        Self::JsxMemberName(node)
    }
}
impl From<JsxName> for AnyJsxElementName {
    fn from(node: JsxName) -> Self {
        Self::JsxName(node)
    }
}
impl From<JsxNamespaceName> for AnyJsxElementName {
    fn from(node: JsxNamespaceName) -> Self {
        Self::JsxNamespaceName(node)
    }
}
impl From<JsxReferenceIdentifier> for AnyJsxElementName {
    fn from(node: JsxReferenceIdentifier) -> Self {
        Self::JsxReferenceIdentifier(node)
    }
}
impl AstNode for AnyJsxElementName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsMetavariable::KIND_SET
        .union(JsxMemberName::KIND_SET)
        .union(JsxName::KIND_SET)
        .union(JsxNamespaceName::KIND_SET)
        .union(JsxReferenceIdentifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_METAVARIABLE
                | JSX_MEMBER_NAME
                | JSX_NAME
                | JSX_NAMESPACE_NAME
                | JSX_REFERENCE_IDENTIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            JSX_MEMBER_NAME => Self::JsxMemberName(JsxMemberName { syntax }),
            JSX_NAME => Self::JsxName(JsxName { syntax }),
            JSX_NAMESPACE_NAME => Self::JsxNamespaceName(JsxNamespaceName { syntax }),
            JSX_REFERENCE_IDENTIFIER => {
                Self::JsxReferenceIdentifier(JsxReferenceIdentifier { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.syntax(),
            Self::JsxMemberName(it) => it.syntax(),
            Self::JsxName(it) => it.syntax(),
            Self::JsxNamespaceName(it) => it.syntax(),
            Self::JsxReferenceIdentifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::JsxMemberName(it) => it.into_syntax(),
            Self::JsxName(it) => it.into_syntax(),
            Self::JsxNamespaceName(it) => it.into_syntax(),
            Self::JsxReferenceIdentifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxElementName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxMemberName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxNamespaceName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxReferenceIdentifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxElementName> for SyntaxNode {
    fn from(n: AnyJsxElementName) -> Self {
        match n {
            AnyJsxElementName::JsMetavariable(it) => it.into_syntax(),
            AnyJsxElementName::JsxMemberName(it) => it.into_syntax(),
            AnyJsxElementName::JsxName(it) => it.into_syntax(),
            AnyJsxElementName::JsxNamespaceName(it) => it.into_syntax(),
            AnyJsxElementName::JsxReferenceIdentifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxElementName> for SyntaxElement {
    fn from(n: AnyJsxElementName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsxName> for AnyJsxName {
    fn from(node: JsxName) -> Self {
        Self::JsxName(node)
    }
}
impl From<JsxNamespaceName> for AnyJsxName {
    fn from(node: JsxNamespaceName) -> Self {
        Self::JsxNamespaceName(node)
    }
}
impl AstNode for AnyJsxName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsxName::KIND_SET.union(JsxNamespaceName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JSX_NAME | JSX_NAMESPACE_NAME)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JSX_NAME => Self::JsxName(JsxName { syntax }),
            JSX_NAMESPACE_NAME => Self::JsxNamespaceName(JsxNamespaceName { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsxName(it) => it.syntax(),
            Self::JsxNamespaceName(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsxName(it) => it.into_syntax(),
            Self::JsxNamespaceName(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsxName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxNamespaceName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxName> for SyntaxNode {
    fn from(n: AnyJsxName) -> Self {
        match n {
            AnyJsxName::JsxName(it) => it.into_syntax(),
            AnyJsxName::JsxNamespaceName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxName> for SyntaxElement {
    fn from(n: AnyJsxName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsxMemberName> for AnyJsxObjectName {
    fn from(node: JsxMemberName) -> Self {
        Self::JsxMemberName(node)
    }
}
impl From<JsxNamespaceName> for AnyJsxObjectName {
    fn from(node: JsxNamespaceName) -> Self {
        Self::JsxNamespaceName(node)
    }
}
impl From<JsxReferenceIdentifier> for AnyJsxObjectName {
    fn from(node: JsxReferenceIdentifier) -> Self {
        Self::JsxReferenceIdentifier(node)
    }
}
impl AstNode for AnyJsxObjectName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsxMemberName::KIND_SET
        .union(JsxNamespaceName::KIND_SET)
        .union(JsxReferenceIdentifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JSX_MEMBER_NAME | JSX_NAMESPACE_NAME | JSX_REFERENCE_IDENTIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JSX_MEMBER_NAME => Self::JsxMemberName(JsxMemberName { syntax }),
            JSX_NAMESPACE_NAME => Self::JsxNamespaceName(JsxNamespaceName { syntax }),
            JSX_REFERENCE_IDENTIFIER => {
                Self::JsxReferenceIdentifier(JsxReferenceIdentifier { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsxMemberName(it) => it.syntax(),
            Self::JsxNamespaceName(it) => it.syntax(),
            Self::JsxReferenceIdentifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsxMemberName(it) => it.into_syntax(),
            Self::JsxNamespaceName(it) => it.into_syntax(),
            Self::JsxReferenceIdentifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxObjectName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsxMemberName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxNamespaceName(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxReferenceIdentifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxObjectName> for SyntaxNode {
    fn from(n: AnyJsxObjectName) -> Self {
        match n {
            AnyJsxObjectName::JsxMemberName(it) => it.into_syntax(),
            AnyJsxObjectName::JsxNamespaceName(it) => it.into_syntax(),
            AnyJsxObjectName::JsxReferenceIdentifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxObjectName> for SyntaxElement {
    fn from(n: AnyJsxObjectName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsxElement> for AnyJsxTag {
    fn from(node: JsxElement) -> Self {
        Self::JsxElement(node)
    }
}
impl From<JsxFragment> for AnyJsxTag {
    fn from(node: JsxFragment) -> Self {
        Self::JsxFragment(node)
    }
}
impl From<JsxSelfClosingElement> for AnyJsxTag {
    fn from(node: JsxSelfClosingElement) -> Self {
        Self::JsxSelfClosingElement(node)
    }
}
impl AstNode for AnyJsxTag {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsxElement::KIND_SET
        .union(JsxFragment::KIND_SET)
        .union(JsxSelfClosingElement::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JSX_ELEMENT | JSX_FRAGMENT | JSX_SELF_CLOSING_ELEMENT)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JSX_ELEMENT => Self::JsxElement(JsxElement { syntax }),
            JSX_FRAGMENT => Self::JsxFragment(JsxFragment { syntax }),
            JSX_SELF_CLOSING_ELEMENT => {
                Self::JsxSelfClosingElement(JsxSelfClosingElement { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsxElement(it) => it.syntax(),
            Self::JsxFragment(it) => it.syntax(),
            Self::JsxSelfClosingElement(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsxElement(it) => it.into_syntax(),
            Self::JsxFragment(it) => it.into_syntax(),
            Self::JsxSelfClosingElement(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyJsxTag {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsxElement(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxFragment(it) => std::fmt::Debug::fmt(it, f),
            Self::JsxSelfClosingElement(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyJsxTag> for SyntaxNode {
    fn from(n: AnyJsxTag) -> Self {
        match n {
            AnyJsxTag::JsxElement(it) => it.into_syntax(),
            AnyJsxTag::JsxFragment(it) => it.into_syntax(),
            AnyJsxTag::JsxSelfClosingElement(it) => it.into_syntax(),
        }
    }
}
impl From<AnyJsxTag> for SyntaxElement {
    fn from(n: AnyJsxTag) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsComputedMemberName> for AnyTsEnumMemberName {
    fn from(node: JsComputedMemberName) -> Self {
        Self::JsComputedMemberName(node)
    }
}
impl From<TsLiteralEnumMemberName> for AnyTsEnumMemberName {
    fn from(node: TsLiteralEnumMemberName) -> Self {
        Self::TsLiteralEnumMemberName(node)
    }
}
impl AstNode for AnyTsEnumMemberName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsComputedMemberName::KIND_SET.union(TsLiteralEnumMemberName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_COMPUTED_MEMBER_NAME | TS_LITERAL_ENUM_MEMBER_NAME)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_COMPUTED_MEMBER_NAME => Self::JsComputedMemberName(JsComputedMemberName { syntax }),
            TS_LITERAL_ENUM_MEMBER_NAME => {
                Self::TsLiteralEnumMemberName(TsLiteralEnumMemberName { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsComputedMemberName(it) => it.syntax(),
            Self::TsLiteralEnumMemberName(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsComputedMemberName(it) => it.into_syntax(),
            Self::TsLiteralEnumMemberName(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsEnumMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsComputedMemberName(it) => std::fmt::Debug::fmt(it, f),
            Self::TsLiteralEnumMemberName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsEnumMemberName> for SyntaxNode {
    fn from(n: AnyTsEnumMemberName) -> Self {
        match n {
            AnyTsEnumMemberName::JsComputedMemberName(it) => it.into_syntax(),
            AnyTsEnumMemberName::TsLiteralEnumMemberName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsEnumMemberName> for SyntaxElement {
    fn from(n: AnyTsEnumMemberName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsEmptyExternalModuleDeclarationBody> for AnyTsExternalModuleDeclarationBody {
    fn from(node: TsEmptyExternalModuleDeclarationBody) -> Self {
        Self::TsEmptyExternalModuleDeclarationBody(node)
    }
}
impl From<TsModuleBlock> for AnyTsExternalModuleDeclarationBody {
    fn from(node: TsModuleBlock) -> Self {
        Self::TsModuleBlock(node)
    }
}
impl AstNode for AnyTsExternalModuleDeclarationBody {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        TsEmptyExternalModuleDeclarationBody::KIND_SET.union(TsModuleBlock::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            TS_EMPTY_EXTERNAL_MODULE_DECLARATION_BODY | TS_MODULE_BLOCK
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_EMPTY_EXTERNAL_MODULE_DECLARATION_BODY => {
                Self::TsEmptyExternalModuleDeclarationBody(TsEmptyExternalModuleDeclarationBody {
                    syntax,
                })
            }
            TS_MODULE_BLOCK => Self::TsModuleBlock(TsModuleBlock { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsEmptyExternalModuleDeclarationBody(it) => it.syntax(),
            Self::TsModuleBlock(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsEmptyExternalModuleDeclarationBody(it) => it.into_syntax(),
            Self::TsModuleBlock(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsExternalModuleDeclarationBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::TsEmptyExternalModuleDeclarationBody(it) => std::fmt::Debug::fmt(it, f),
            Self::TsModuleBlock(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsExternalModuleDeclarationBody> for SyntaxNode {
    fn from(n: AnyTsExternalModuleDeclarationBody) -> Self {
        match n {
            AnyTsExternalModuleDeclarationBody::TsEmptyExternalModuleDeclarationBody(it) => {
                it.into_syntax()
            }
            AnyTsExternalModuleDeclarationBody::TsModuleBlock(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsExternalModuleDeclarationBody> for SyntaxElement {
    fn from(n: AnyTsExternalModuleDeclarationBody) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsMetavariable> for AnyTsIdentifierBinding {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<TsIdentifierBinding> for AnyTsIdentifierBinding {
    fn from(node: TsIdentifierBinding) -> Self {
        Self::TsIdentifierBinding(node)
    }
}
impl AstNode for AnyTsIdentifierBinding {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsMetavariable::KIND_SET.union(TsIdentifierBinding::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_METAVARIABLE | TS_IDENTIFIER_BINDING)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            TS_IDENTIFIER_BINDING => Self::TsIdentifierBinding(TsIdentifierBinding { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.syntax(),
            Self::TsIdentifierBinding(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::TsIdentifierBinding(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsIdentifierBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::TsIdentifierBinding(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsIdentifierBinding> for SyntaxNode {
    fn from(n: AnyTsIdentifierBinding) -> Self {
        match n {
            AnyTsIdentifierBinding::JsMetavariable(it) => it.into_syntax(),
            AnyTsIdentifierBinding::TsIdentifierBinding(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsIdentifierBinding> for SyntaxElement {
    fn from(n: AnyTsIdentifierBinding) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsStaticModifier> for AnyTsIndexSignatureModifier {
    fn from(node: JsStaticModifier) -> Self {
        Self::JsStaticModifier(node)
    }
}
impl From<TsReadonlyModifier> for AnyTsIndexSignatureModifier {
    fn from(node: TsReadonlyModifier) -> Self {
        Self::TsReadonlyModifier(node)
    }
}
impl AstNode for AnyTsIndexSignatureModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsStaticModifier::KIND_SET.union(TsReadonlyModifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_STATIC_MODIFIER | TS_READONLY_MODIFIER)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_STATIC_MODIFIER => Self::JsStaticModifier(JsStaticModifier { syntax }),
            TS_READONLY_MODIFIER => Self::TsReadonlyModifier(TsReadonlyModifier { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsStaticModifier(it) => it.syntax(),
            Self::TsReadonlyModifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsStaticModifier(it) => it.into_syntax(),
            Self::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsIndexSignatureModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsStaticModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsReadonlyModifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsIndexSignatureModifier> for SyntaxNode {
    fn from(n: AnyTsIndexSignatureModifier) -> Self {
        match n {
            AnyTsIndexSignatureModifier::JsStaticModifier(it) => it.into_syntax(),
            AnyTsIndexSignatureModifier::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsIndexSignatureModifier> for SyntaxElement {
    fn from(n: AnyTsIndexSignatureModifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsDecorator> for AnyTsMethodSignatureModifier {
    fn from(node: JsDecorator) -> Self {
        Self::JsDecorator(node)
    }
}
impl From<JsStaticModifier> for AnyTsMethodSignatureModifier {
    fn from(node: JsStaticModifier) -> Self {
        Self::JsStaticModifier(node)
    }
}
impl From<TsAbstractModifier> for AnyTsMethodSignatureModifier {
    fn from(node: TsAbstractModifier) -> Self {
        Self::TsAbstractModifier(node)
    }
}
impl From<TsAccessibilityModifier> for AnyTsMethodSignatureModifier {
    fn from(node: TsAccessibilityModifier) -> Self {
        Self::TsAccessibilityModifier(node)
    }
}
impl From<TsOverrideModifier> for AnyTsMethodSignatureModifier {
    fn from(node: TsOverrideModifier) -> Self {
        Self::TsOverrideModifier(node)
    }
}
impl AstNode for AnyTsMethodSignatureModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsDecorator::KIND_SET
        .union(JsStaticModifier::KIND_SET)
        .union(TsAbstractModifier::KIND_SET)
        .union(TsAccessibilityModifier::KIND_SET)
        .union(TsOverrideModifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_DECORATOR
                | JS_STATIC_MODIFIER
                | TS_ABSTRACT_MODIFIER
                | TS_ACCESSIBILITY_MODIFIER
                | TS_OVERRIDE_MODIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_DECORATOR => Self::JsDecorator(JsDecorator { syntax }),
            JS_STATIC_MODIFIER => Self::JsStaticModifier(JsStaticModifier { syntax }),
            TS_ABSTRACT_MODIFIER => Self::TsAbstractModifier(TsAbstractModifier { syntax }),
            TS_ACCESSIBILITY_MODIFIER => {
                Self::TsAccessibilityModifier(TsAccessibilityModifier { syntax })
            }
            TS_OVERRIDE_MODIFIER => Self::TsOverrideModifier(TsOverrideModifier { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsDecorator(it) => it.syntax(),
            Self::JsStaticModifier(it) => it.syntax(),
            Self::TsAbstractModifier(it) => it.syntax(),
            Self::TsAccessibilityModifier(it) => it.syntax(),
            Self::TsOverrideModifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsDecorator(it) => it.into_syntax(),
            Self::JsStaticModifier(it) => it.into_syntax(),
            Self::TsAbstractModifier(it) => it.into_syntax(),
            Self::TsAccessibilityModifier(it) => it.into_syntax(),
            Self::TsOverrideModifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsMethodSignatureModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsDecorator(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAbstractModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAccessibilityModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOverrideModifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsMethodSignatureModifier> for SyntaxNode {
    fn from(n: AnyTsMethodSignatureModifier) -> Self {
        match n {
            AnyTsMethodSignatureModifier::JsDecorator(it) => it.into_syntax(),
            AnyTsMethodSignatureModifier::JsStaticModifier(it) => it.into_syntax(),
            AnyTsMethodSignatureModifier::TsAbstractModifier(it) => it.into_syntax(),
            AnyTsMethodSignatureModifier::TsAccessibilityModifier(it) => it.into_syntax(),
            AnyTsMethodSignatureModifier::TsOverrideModifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsMethodSignatureModifier> for SyntaxElement {
    fn from(n: AnyTsMethodSignatureModifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsQualifiedModuleName> for AnyTsModuleName {
    fn from(node: TsQualifiedModuleName) -> Self {
        Self::TsQualifiedModuleName(node)
    }
}
impl AstNode for AnyTsModuleName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        AnyTsIdentifierBinding::KIND_SET.union(TsQualifiedModuleName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            TS_QUALIFIED_MODULE_NAME => true,
            k if AnyTsIdentifierBinding::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_QUALIFIED_MODULE_NAME => {
                Self::TsQualifiedModuleName(TsQualifiedModuleName { syntax })
            }
            _ => {
                if let Some(any_ts_identifier_binding) = AnyTsIdentifierBinding::cast(syntax) {
                    return Some(Self::AnyTsIdentifierBinding(any_ts_identifier_binding));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsQualifiedModuleName(it) => it.syntax(),
            Self::AnyTsIdentifierBinding(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsQualifiedModuleName(it) => it.into_syntax(),
            Self::AnyTsIdentifierBinding(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsModuleName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyTsIdentifierBinding(it) => std::fmt::Debug::fmt(it, f),
            Self::TsQualifiedModuleName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsModuleName> for SyntaxNode {
    fn from(n: AnyTsModuleName) -> Self {
        match n {
            AnyTsModuleName::AnyTsIdentifierBinding(it) => it.into_syntax(),
            AnyTsModuleName::TsQualifiedModuleName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsModuleName> for SyntaxElement {
    fn from(n: AnyTsModuleName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsExternalModuleReference> for AnyTsModuleReference {
    fn from(node: TsExternalModuleReference) -> Self {
        Self::TsExternalModuleReference(node)
    }
}
impl AstNode for AnyTsModuleReference {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        AnyTsName::KIND_SET.union(TsExternalModuleReference::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            TS_EXTERNAL_MODULE_REFERENCE => true,
            k if AnyTsName::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_EXTERNAL_MODULE_REFERENCE => {
                Self::TsExternalModuleReference(TsExternalModuleReference { syntax })
            }
            _ => {
                if let Some(any_ts_name) = AnyTsName::cast(syntax) {
                    return Some(Self::AnyTsName(any_ts_name));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsExternalModuleReference(it) => it.syntax(),
            Self::AnyTsName(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsExternalModuleReference(it) => it.into_syntax(),
            Self::AnyTsName(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsModuleReference {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyTsName(it) => std::fmt::Debug::fmt(it, f),
            Self::TsExternalModuleReference(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsModuleReference> for SyntaxNode {
    fn from(n: AnyTsModuleReference) -> Self {
        match n {
            AnyTsModuleReference::AnyTsName(it) => it.into_syntax(),
            AnyTsModuleReference::TsExternalModuleReference(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsModuleReference> for SyntaxElement {
    fn from(n: AnyTsModuleReference) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsReferenceIdentifier> for AnyTsName {
    fn from(node: JsReferenceIdentifier) -> Self {
        Self::JsReferenceIdentifier(node)
    }
}
impl From<TsQualifiedName> for AnyTsName {
    fn from(node: TsQualifiedName) -> Self {
        Self::TsQualifiedName(node)
    }
}
impl AstNode for AnyTsName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsReferenceIdentifier::KIND_SET.union(TsQualifiedName::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_REFERENCE_IDENTIFIER | TS_QUALIFIED_NAME)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_REFERENCE_IDENTIFIER => {
                Self::JsReferenceIdentifier(JsReferenceIdentifier { syntax })
            }
            TS_QUALIFIED_NAME => Self::TsQualifiedName(TsQualifiedName { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsReferenceIdentifier(it) => it.syntax(),
            Self::TsQualifiedName(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsReferenceIdentifier(it) => it.into_syntax(),
            Self::TsQualifiedName(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsReferenceIdentifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsQualifiedName(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsName> for SyntaxNode {
    fn from(n: AnyTsName) -> Self {
        match n {
            AnyTsName::JsReferenceIdentifier(it) => it.into_syntax(),
            AnyTsName::TsQualifiedName(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsName> for SyntaxElement {
    fn from(n: AnyTsName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsDefinitePropertyAnnotation> for AnyTsPropertyAnnotation {
    fn from(node: TsDefinitePropertyAnnotation) -> Self {
        Self::TsDefinitePropertyAnnotation(node)
    }
}
impl From<TsOptionalPropertyAnnotation> for AnyTsPropertyAnnotation {
    fn from(node: TsOptionalPropertyAnnotation) -> Self {
        Self::TsOptionalPropertyAnnotation(node)
    }
}
impl From<TsTypeAnnotation> for AnyTsPropertyAnnotation {
    fn from(node: TsTypeAnnotation) -> Self {
        Self::TsTypeAnnotation(node)
    }
}
impl AstNode for AnyTsPropertyAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = TsDefinitePropertyAnnotation::KIND_SET
        .union(TsOptionalPropertyAnnotation::KIND_SET)
        .union(TsTypeAnnotation::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            TS_DEFINITE_PROPERTY_ANNOTATION | TS_OPTIONAL_PROPERTY_ANNOTATION | TS_TYPE_ANNOTATION
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_DEFINITE_PROPERTY_ANNOTATION => {
                Self::TsDefinitePropertyAnnotation(TsDefinitePropertyAnnotation { syntax })
            }
            TS_OPTIONAL_PROPERTY_ANNOTATION => {
                Self::TsOptionalPropertyAnnotation(TsOptionalPropertyAnnotation { syntax })
            }
            TS_TYPE_ANNOTATION => Self::TsTypeAnnotation(TsTypeAnnotation { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsDefinitePropertyAnnotation(it) => it.syntax(),
            Self::TsOptionalPropertyAnnotation(it) => it.syntax(),
            Self::TsTypeAnnotation(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsDefinitePropertyAnnotation(it) => it.into_syntax(),
            Self::TsOptionalPropertyAnnotation(it) => it.into_syntax(),
            Self::TsTypeAnnotation(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsPropertyAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::TsDefinitePropertyAnnotation(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOptionalPropertyAnnotation(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAnnotation(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsPropertyAnnotation> for SyntaxNode {
    fn from(n: AnyTsPropertyAnnotation) -> Self {
        match n {
            AnyTsPropertyAnnotation::TsDefinitePropertyAnnotation(it) => it.into_syntax(),
            AnyTsPropertyAnnotation::TsOptionalPropertyAnnotation(it) => it.into_syntax(),
            AnyTsPropertyAnnotation::TsTypeAnnotation(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsPropertyAnnotation> for SyntaxElement {
    fn from(n: AnyTsPropertyAnnotation) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsAccessibilityModifier> for AnyTsPropertyParameterModifier {
    fn from(node: TsAccessibilityModifier) -> Self {
        Self::TsAccessibilityModifier(node)
    }
}
impl From<TsOverrideModifier> for AnyTsPropertyParameterModifier {
    fn from(node: TsOverrideModifier) -> Self {
        Self::TsOverrideModifier(node)
    }
}
impl From<TsReadonlyModifier> for AnyTsPropertyParameterModifier {
    fn from(node: TsReadonlyModifier) -> Self {
        Self::TsReadonlyModifier(node)
    }
}
impl AstNode for AnyTsPropertyParameterModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = TsAccessibilityModifier::KIND_SET
        .union(TsOverrideModifier::KIND_SET)
        .union(TsReadonlyModifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            TS_ACCESSIBILITY_MODIFIER | TS_OVERRIDE_MODIFIER | TS_READONLY_MODIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_ACCESSIBILITY_MODIFIER => {
                Self::TsAccessibilityModifier(TsAccessibilityModifier { syntax })
            }
            TS_OVERRIDE_MODIFIER => Self::TsOverrideModifier(TsOverrideModifier { syntax }),
            TS_READONLY_MODIFIER => Self::TsReadonlyModifier(TsReadonlyModifier { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsAccessibilityModifier(it) => it.syntax(),
            Self::TsOverrideModifier(it) => it.syntax(),
            Self::TsReadonlyModifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsAccessibilityModifier(it) => it.into_syntax(),
            Self::TsOverrideModifier(it) => it.into_syntax(),
            Self::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsPropertyParameterModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::TsAccessibilityModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOverrideModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsReadonlyModifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsPropertyParameterModifier> for SyntaxNode {
    fn from(n: AnyTsPropertyParameterModifier) -> Self {
        match n {
            AnyTsPropertyParameterModifier::TsAccessibilityModifier(it) => it.into_syntax(),
            AnyTsPropertyParameterModifier::TsOverrideModifier(it) => it.into_syntax(),
            AnyTsPropertyParameterModifier::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsPropertyParameterModifier> for SyntaxElement {
    fn from(n: AnyTsPropertyParameterModifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsOptionalPropertyAnnotation> for AnyTsPropertySignatureAnnotation {
    fn from(node: TsOptionalPropertyAnnotation) -> Self {
        Self::TsOptionalPropertyAnnotation(node)
    }
}
impl From<TsTypeAnnotation> for AnyTsPropertySignatureAnnotation {
    fn from(node: TsTypeAnnotation) -> Self {
        Self::TsTypeAnnotation(node)
    }
}
impl AstNode for AnyTsPropertySignatureAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        TsOptionalPropertyAnnotation::KIND_SET.union(TsTypeAnnotation::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, TS_OPTIONAL_PROPERTY_ANNOTATION | TS_TYPE_ANNOTATION)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_OPTIONAL_PROPERTY_ANNOTATION => {
                Self::TsOptionalPropertyAnnotation(TsOptionalPropertyAnnotation { syntax })
            }
            TS_TYPE_ANNOTATION => Self::TsTypeAnnotation(TsTypeAnnotation { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsOptionalPropertyAnnotation(it) => it.syntax(),
            Self::TsTypeAnnotation(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsOptionalPropertyAnnotation(it) => it.into_syntax(),
            Self::TsTypeAnnotation(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsPropertySignatureAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::TsOptionalPropertyAnnotation(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAnnotation(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsPropertySignatureAnnotation> for SyntaxNode {
    fn from(n: AnyTsPropertySignatureAnnotation) -> Self {
        match n {
            AnyTsPropertySignatureAnnotation::TsOptionalPropertyAnnotation(it) => it.into_syntax(),
            AnyTsPropertySignatureAnnotation::TsTypeAnnotation(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsPropertySignatureAnnotation> for SyntaxElement {
    fn from(n: AnyTsPropertySignatureAnnotation) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsAccessorModifier> for AnyTsPropertySignatureModifier {
    fn from(node: JsAccessorModifier) -> Self {
        Self::JsAccessorModifier(node)
    }
}
impl From<JsDecorator> for AnyTsPropertySignatureModifier {
    fn from(node: JsDecorator) -> Self {
        Self::JsDecorator(node)
    }
}
impl From<JsStaticModifier> for AnyTsPropertySignatureModifier {
    fn from(node: JsStaticModifier) -> Self {
        Self::JsStaticModifier(node)
    }
}
impl From<TsAbstractModifier> for AnyTsPropertySignatureModifier {
    fn from(node: TsAbstractModifier) -> Self {
        Self::TsAbstractModifier(node)
    }
}
impl From<TsAccessibilityModifier> for AnyTsPropertySignatureModifier {
    fn from(node: TsAccessibilityModifier) -> Self {
        Self::TsAccessibilityModifier(node)
    }
}
impl From<TsDeclareModifier> for AnyTsPropertySignatureModifier {
    fn from(node: TsDeclareModifier) -> Self {
        Self::TsDeclareModifier(node)
    }
}
impl From<TsOverrideModifier> for AnyTsPropertySignatureModifier {
    fn from(node: TsOverrideModifier) -> Self {
        Self::TsOverrideModifier(node)
    }
}
impl From<TsReadonlyModifier> for AnyTsPropertySignatureModifier {
    fn from(node: TsReadonlyModifier) -> Self {
        Self::TsReadonlyModifier(node)
    }
}
impl AstNode for AnyTsPropertySignatureModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsAccessorModifier::KIND_SET
        .union(JsDecorator::KIND_SET)
        .union(JsStaticModifier::KIND_SET)
        .union(TsAbstractModifier::KIND_SET)
        .union(TsAccessibilityModifier::KIND_SET)
        .union(TsDeclareModifier::KIND_SET)
        .union(TsOverrideModifier::KIND_SET)
        .union(TsReadonlyModifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_ACCESSOR_MODIFIER
                | JS_DECORATOR
                | JS_STATIC_MODIFIER
                | TS_ABSTRACT_MODIFIER
                | TS_ACCESSIBILITY_MODIFIER
                | TS_DECLARE_MODIFIER
                | TS_OVERRIDE_MODIFIER
                | TS_READONLY_MODIFIER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_ACCESSOR_MODIFIER => Self::JsAccessorModifier(JsAccessorModifier { syntax }),
            JS_DECORATOR => Self::JsDecorator(JsDecorator { syntax }),
            JS_STATIC_MODIFIER => Self::JsStaticModifier(JsStaticModifier { syntax }),
            TS_ABSTRACT_MODIFIER => Self::TsAbstractModifier(TsAbstractModifier { syntax }),
            TS_ACCESSIBILITY_MODIFIER => {
                Self::TsAccessibilityModifier(TsAccessibilityModifier { syntax })
            }
            TS_DECLARE_MODIFIER => Self::TsDeclareModifier(TsDeclareModifier { syntax }),
            TS_OVERRIDE_MODIFIER => Self::TsOverrideModifier(TsOverrideModifier { syntax }),
            TS_READONLY_MODIFIER => Self::TsReadonlyModifier(TsReadonlyModifier { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsAccessorModifier(it) => it.syntax(),
            Self::JsDecorator(it) => it.syntax(),
            Self::JsStaticModifier(it) => it.syntax(),
            Self::TsAbstractModifier(it) => it.syntax(),
            Self::TsAccessibilityModifier(it) => it.syntax(),
            Self::TsDeclareModifier(it) => it.syntax(),
            Self::TsOverrideModifier(it) => it.syntax(),
            Self::TsReadonlyModifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsAccessorModifier(it) => it.into_syntax(),
            Self::JsDecorator(it) => it.into_syntax(),
            Self::JsStaticModifier(it) => it.into_syntax(),
            Self::TsAbstractModifier(it) => it.into_syntax(),
            Self::TsAccessibilityModifier(it) => it.into_syntax(),
            Self::TsDeclareModifier(it) => it.into_syntax(),
            Self::TsOverrideModifier(it) => it.into_syntax(),
            Self::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsPropertySignatureModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsAccessorModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::JsDecorator(it) => std::fmt::Debug::fmt(it, f),
            Self::JsStaticModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAbstractModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAccessibilityModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsDeclareModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOverrideModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsReadonlyModifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsPropertySignatureModifier> for SyntaxNode {
    fn from(n: AnyTsPropertySignatureModifier) -> Self {
        match n {
            AnyTsPropertySignatureModifier::JsAccessorModifier(it) => it.into_syntax(),
            AnyTsPropertySignatureModifier::JsDecorator(it) => it.into_syntax(),
            AnyTsPropertySignatureModifier::JsStaticModifier(it) => it.into_syntax(),
            AnyTsPropertySignatureModifier::TsAbstractModifier(it) => it.into_syntax(),
            AnyTsPropertySignatureModifier::TsAccessibilityModifier(it) => it.into_syntax(),
            AnyTsPropertySignatureModifier::TsDeclareModifier(it) => it.into_syntax(),
            AnyTsPropertySignatureModifier::TsOverrideModifier(it) => it.into_syntax(),
            AnyTsPropertySignatureModifier::TsReadonlyModifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsPropertySignatureModifier> for SyntaxElement {
    fn from(n: AnyTsPropertySignatureModifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsAssertsReturnType> for AnyTsReturnType {
    fn from(node: TsAssertsReturnType) -> Self {
        Self::TsAssertsReturnType(node)
    }
}
impl From<TsPredicateReturnType> for AnyTsReturnType {
    fn from(node: TsPredicateReturnType) -> Self {
        Self::TsPredicateReturnType(node)
    }
}
impl AstNode for AnyTsReturnType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyTsType::KIND_SET
        .union(TsAssertsReturnType::KIND_SET)
        .union(TsPredicateReturnType::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            TS_ASSERTS_RETURN_TYPE | TS_PREDICATE_RETURN_TYPE => true,
            k if AnyTsType::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_ASSERTS_RETURN_TYPE => Self::TsAssertsReturnType(TsAssertsReturnType { syntax }),
            TS_PREDICATE_RETURN_TYPE => {
                Self::TsPredicateReturnType(TsPredicateReturnType { syntax })
            }
            _ => {
                if let Some(any_ts_type) = AnyTsType::cast(syntax) {
                    return Some(Self::AnyTsType(any_ts_type));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsAssertsReturnType(it) => it.syntax(),
            Self::TsPredicateReturnType(it) => it.syntax(),
            Self::AnyTsType(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsAssertsReturnType(it) => it.into_syntax(),
            Self::TsPredicateReturnType(it) => it.into_syntax(),
            Self::AnyTsType(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsReturnType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyTsType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAssertsReturnType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsPredicateReturnType(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsReturnType> for SyntaxNode {
    fn from(n: AnyTsReturnType) -> Self {
        match n {
            AnyTsReturnType::AnyTsType(it) => it.into_syntax(),
            AnyTsReturnType::TsAssertsReturnType(it) => it.into_syntax(),
            AnyTsReturnType::TsPredicateReturnType(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsReturnType> for SyntaxElement {
    fn from(n: AnyTsReturnType) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsTemplateChunkElement> for AnyTsTemplateElement {
    fn from(node: TsTemplateChunkElement) -> Self {
        Self::TsTemplateChunkElement(node)
    }
}
impl From<TsTemplateElement> for AnyTsTemplateElement {
    fn from(node: TsTemplateElement) -> Self {
        Self::TsTemplateElement(node)
    }
}
impl AstNode for AnyTsTemplateElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        TsTemplateChunkElement::KIND_SET.union(TsTemplateElement::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, TS_TEMPLATE_CHUNK_ELEMENT | TS_TEMPLATE_ELEMENT)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_TEMPLATE_CHUNK_ELEMENT => {
                Self::TsTemplateChunkElement(TsTemplateChunkElement { syntax })
            }
            TS_TEMPLATE_ELEMENT => Self::TsTemplateElement(TsTemplateElement { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsTemplateChunkElement(it) => it.syntax(),
            Self::TsTemplateElement(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsTemplateChunkElement(it) => it.into_syntax(),
            Self::TsTemplateElement(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::TsTemplateChunkElement(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTemplateElement(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsTemplateElement> for SyntaxNode {
    fn from(n: AnyTsTemplateElement) -> Self {
        match n {
            AnyTsTemplateElement::TsTemplateChunkElement(it) => it.into_syntax(),
            AnyTsTemplateElement::TsTemplateElement(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsTemplateElement> for SyntaxElement {
    fn from(n: AnyTsTemplateElement) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsNamedTupleTypeElement> for AnyTsTupleTypeElement {
    fn from(node: TsNamedTupleTypeElement) -> Self {
        Self::TsNamedTupleTypeElement(node)
    }
}
impl From<TsOptionalTupleTypeElement> for AnyTsTupleTypeElement {
    fn from(node: TsOptionalTupleTypeElement) -> Self {
        Self::TsOptionalTupleTypeElement(node)
    }
}
impl From<TsRestTupleTypeElement> for AnyTsTupleTypeElement {
    fn from(node: TsRestTupleTypeElement) -> Self {
        Self::TsRestTupleTypeElement(node)
    }
}
impl AstNode for AnyTsTupleTypeElement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = AnyTsType::KIND_SET
        .union(TsNamedTupleTypeElement::KIND_SET)
        .union(TsOptionalTupleTypeElement::KIND_SET)
        .union(TsRestTupleTypeElement::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        match kind {
            TS_NAMED_TUPLE_TYPE_ELEMENT
            | TS_OPTIONAL_TUPLE_TYPE_ELEMENT
            | TS_REST_TUPLE_TYPE_ELEMENT => true,
            k if AnyTsType::can_cast(k) => true,
            _ => false,
        }
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_NAMED_TUPLE_TYPE_ELEMENT => {
                Self::TsNamedTupleTypeElement(TsNamedTupleTypeElement { syntax })
            }
            TS_OPTIONAL_TUPLE_TYPE_ELEMENT => {
                Self::TsOptionalTupleTypeElement(TsOptionalTupleTypeElement { syntax })
            }
            TS_REST_TUPLE_TYPE_ELEMENT => {
                Self::TsRestTupleTypeElement(TsRestTupleTypeElement { syntax })
            }
            _ => {
                if let Some(any_ts_type) = AnyTsType::cast(syntax) {
                    return Some(Self::AnyTsType(any_ts_type));
                }
                return None;
            }
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsNamedTupleTypeElement(it) => it.syntax(),
            Self::TsOptionalTupleTypeElement(it) => it.syntax(),
            Self::TsRestTupleTypeElement(it) => it.syntax(),
            Self::AnyTsType(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsNamedTupleTypeElement(it) => it.into_syntax(),
            Self::TsOptionalTupleTypeElement(it) => it.into_syntax(),
            Self::TsRestTupleTypeElement(it) => it.into_syntax(),
            Self::AnyTsType(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::AnyTsType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNamedTupleTypeElement(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOptionalTupleTypeElement(it) => std::fmt::Debug::fmt(it, f),
            Self::TsRestTupleTypeElement(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsTupleTypeElement> for SyntaxNode {
    fn from(n: AnyTsTupleTypeElement) -> Self {
        match n {
            AnyTsTupleTypeElement::AnyTsType(it) => it.into_syntax(),
            AnyTsTupleTypeElement::TsNamedTupleTypeElement(it) => it.into_syntax(),
            AnyTsTupleTypeElement::TsOptionalTupleTypeElement(it) => it.into_syntax(),
            AnyTsTupleTypeElement::TsRestTupleTypeElement(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsTupleTypeElement> for SyntaxElement {
    fn from(n: AnyTsTupleTypeElement) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsMetavariable> for AnyTsType {
    fn from(node: JsMetavariable) -> Self {
        Self::JsMetavariable(node)
    }
}
impl From<TsAnyType> for AnyTsType {
    fn from(node: TsAnyType) -> Self {
        Self::TsAnyType(node)
    }
}
impl From<TsArrayType> for AnyTsType {
    fn from(node: TsArrayType) -> Self {
        Self::TsArrayType(node)
    }
}
impl From<TsBigintLiteralType> for AnyTsType {
    fn from(node: TsBigintLiteralType) -> Self {
        Self::TsBigintLiteralType(node)
    }
}
impl From<TsBigintType> for AnyTsType {
    fn from(node: TsBigintType) -> Self {
        Self::TsBigintType(node)
    }
}
impl From<TsBogusType> for AnyTsType {
    fn from(node: TsBogusType) -> Self {
        Self::TsBogusType(node)
    }
}
impl From<TsBooleanLiteralType> for AnyTsType {
    fn from(node: TsBooleanLiteralType) -> Self {
        Self::TsBooleanLiteralType(node)
    }
}
impl From<TsBooleanType> for AnyTsType {
    fn from(node: TsBooleanType) -> Self {
        Self::TsBooleanType(node)
    }
}
impl From<TsConditionalType> for AnyTsType {
    fn from(node: TsConditionalType) -> Self {
        Self::TsConditionalType(node)
    }
}
impl From<TsConstructorType> for AnyTsType {
    fn from(node: TsConstructorType) -> Self {
        Self::TsConstructorType(node)
    }
}
impl From<TsFunctionType> for AnyTsType {
    fn from(node: TsFunctionType) -> Self {
        Self::TsFunctionType(node)
    }
}
impl From<TsImportType> for AnyTsType {
    fn from(node: TsImportType) -> Self {
        Self::TsImportType(node)
    }
}
impl From<TsIndexedAccessType> for AnyTsType {
    fn from(node: TsIndexedAccessType) -> Self {
        Self::TsIndexedAccessType(node)
    }
}
impl From<TsInferType> for AnyTsType {
    fn from(node: TsInferType) -> Self {
        Self::TsInferType(node)
    }
}
impl From<TsIntersectionType> for AnyTsType {
    fn from(node: TsIntersectionType) -> Self {
        Self::TsIntersectionType(node)
    }
}
impl From<TsMappedType> for AnyTsType {
    fn from(node: TsMappedType) -> Self {
        Self::TsMappedType(node)
    }
}
impl From<TsNeverType> for AnyTsType {
    fn from(node: TsNeverType) -> Self {
        Self::TsNeverType(node)
    }
}
impl From<TsNonPrimitiveType> for AnyTsType {
    fn from(node: TsNonPrimitiveType) -> Self {
        Self::TsNonPrimitiveType(node)
    }
}
impl From<TsNullLiteralType> for AnyTsType {
    fn from(node: TsNullLiteralType) -> Self {
        Self::TsNullLiteralType(node)
    }
}
impl From<TsNumberLiteralType> for AnyTsType {
    fn from(node: TsNumberLiteralType) -> Self {
        Self::TsNumberLiteralType(node)
    }
}
impl From<TsNumberType> for AnyTsType {
    fn from(node: TsNumberType) -> Self {
        Self::TsNumberType(node)
    }
}
impl From<TsObjectType> for AnyTsType {
    fn from(node: TsObjectType) -> Self {
        Self::TsObjectType(node)
    }
}
impl From<TsParenthesizedType> for AnyTsType {
    fn from(node: TsParenthesizedType) -> Self {
        Self::TsParenthesizedType(node)
    }
}
impl From<TsReferenceType> for AnyTsType {
    fn from(node: TsReferenceType) -> Self {
        Self::TsReferenceType(node)
    }
}
impl From<TsStringLiteralType> for AnyTsType {
    fn from(node: TsStringLiteralType) -> Self {
        Self::TsStringLiteralType(node)
    }
}
impl From<TsStringType> for AnyTsType {
    fn from(node: TsStringType) -> Self {
        Self::TsStringType(node)
    }
}
impl From<TsSymbolType> for AnyTsType {
    fn from(node: TsSymbolType) -> Self {
        Self::TsSymbolType(node)
    }
}
impl From<TsTemplateLiteralType> for AnyTsType {
    fn from(node: TsTemplateLiteralType) -> Self {
        Self::TsTemplateLiteralType(node)
    }
}
impl From<TsThisType> for AnyTsType {
    fn from(node: TsThisType) -> Self {
        Self::TsThisType(node)
    }
}
impl From<TsTupleType> for AnyTsType {
    fn from(node: TsTupleType) -> Self {
        Self::TsTupleType(node)
    }
}
impl From<TsTypeOperatorType> for AnyTsType {
    fn from(node: TsTypeOperatorType) -> Self {
        Self::TsTypeOperatorType(node)
    }
}
impl From<TsTypeofType> for AnyTsType {
    fn from(node: TsTypeofType) -> Self {
        Self::TsTypeofType(node)
    }
}
impl From<TsUndefinedType> for AnyTsType {
    fn from(node: TsUndefinedType) -> Self {
        Self::TsUndefinedType(node)
    }
}
impl From<TsUnionType> for AnyTsType {
    fn from(node: TsUnionType) -> Self {
        Self::TsUnionType(node)
    }
}
impl From<TsUnknownType> for AnyTsType {
    fn from(node: TsUnknownType) -> Self {
        Self::TsUnknownType(node)
    }
}
impl From<TsVoidType> for AnyTsType {
    fn from(node: TsVoidType) -> Self {
        Self::TsVoidType(node)
    }
}
impl AstNode for AnyTsType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsMetavariable::KIND_SET
        .union(TsAnyType::KIND_SET)
        .union(TsArrayType::KIND_SET)
        .union(TsBigintLiteralType::KIND_SET)
        .union(TsBigintType::KIND_SET)
        .union(TsBogusType::KIND_SET)
        .union(TsBooleanLiteralType::KIND_SET)
        .union(TsBooleanType::KIND_SET)
        .union(TsConditionalType::KIND_SET)
        .union(TsConstructorType::KIND_SET)
        .union(TsFunctionType::KIND_SET)
        .union(TsImportType::KIND_SET)
        .union(TsIndexedAccessType::KIND_SET)
        .union(TsInferType::KIND_SET)
        .union(TsIntersectionType::KIND_SET)
        .union(TsMappedType::KIND_SET)
        .union(TsNeverType::KIND_SET)
        .union(TsNonPrimitiveType::KIND_SET)
        .union(TsNullLiteralType::KIND_SET)
        .union(TsNumberLiteralType::KIND_SET)
        .union(TsNumberType::KIND_SET)
        .union(TsObjectType::KIND_SET)
        .union(TsParenthesizedType::KIND_SET)
        .union(TsReferenceType::KIND_SET)
        .union(TsStringLiteralType::KIND_SET)
        .union(TsStringType::KIND_SET)
        .union(TsSymbolType::KIND_SET)
        .union(TsTemplateLiteralType::KIND_SET)
        .union(TsThisType::KIND_SET)
        .union(TsTupleType::KIND_SET)
        .union(TsTypeOperatorType::KIND_SET)
        .union(TsTypeofType::KIND_SET)
        .union(TsUndefinedType::KIND_SET)
        .union(TsUnionType::KIND_SET)
        .union(TsUnknownType::KIND_SET)
        .union(TsVoidType::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_METAVARIABLE
                | TS_ANY_TYPE
                | TS_ARRAY_TYPE
                | TS_BIGINT_LITERAL_TYPE
                | TS_BIGINT_TYPE
                | TS_BOGUS_TYPE
                | TS_BOOLEAN_LITERAL_TYPE
                | TS_BOOLEAN_TYPE
                | TS_CONDITIONAL_TYPE
                | TS_CONSTRUCTOR_TYPE
                | TS_FUNCTION_TYPE
                | TS_IMPORT_TYPE
                | TS_INDEXED_ACCESS_TYPE
                | TS_INFER_TYPE
                | TS_INTERSECTION_TYPE
                | TS_MAPPED_TYPE
                | TS_NEVER_TYPE
                | TS_NON_PRIMITIVE_TYPE
                | TS_NULL_LITERAL_TYPE
                | TS_NUMBER_LITERAL_TYPE
                | TS_NUMBER_TYPE
                | TS_OBJECT_TYPE
                | TS_PARENTHESIZED_TYPE
                | TS_REFERENCE_TYPE
                | TS_STRING_LITERAL_TYPE
                | TS_STRING_TYPE
                | TS_SYMBOL_TYPE
                | TS_TEMPLATE_LITERAL_TYPE
                | TS_THIS_TYPE
                | TS_TUPLE_TYPE
                | TS_TYPE_OPERATOR_TYPE
                | TS_TYPEOF_TYPE
                | TS_UNDEFINED_TYPE
                | TS_UNION_TYPE
                | TS_UNKNOWN_TYPE
                | TS_VOID_TYPE
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_METAVARIABLE => Self::JsMetavariable(JsMetavariable { syntax }),
            TS_ANY_TYPE => Self::TsAnyType(TsAnyType { syntax }),
            TS_ARRAY_TYPE => Self::TsArrayType(TsArrayType { syntax }),
            TS_BIGINT_LITERAL_TYPE => Self::TsBigintLiteralType(TsBigintLiteralType { syntax }),
            TS_BIGINT_TYPE => Self::TsBigintType(TsBigintType { syntax }),
            TS_BOGUS_TYPE => Self::TsBogusType(TsBogusType { syntax }),
            TS_BOOLEAN_LITERAL_TYPE => Self::TsBooleanLiteralType(TsBooleanLiteralType { syntax }),
            TS_BOOLEAN_TYPE => Self::TsBooleanType(TsBooleanType { syntax }),
            TS_CONDITIONAL_TYPE => Self::TsConditionalType(TsConditionalType { syntax }),
            TS_CONSTRUCTOR_TYPE => Self::TsConstructorType(TsConstructorType { syntax }),
            TS_FUNCTION_TYPE => Self::TsFunctionType(TsFunctionType { syntax }),
            TS_IMPORT_TYPE => Self::TsImportType(TsImportType { syntax }),
            TS_INDEXED_ACCESS_TYPE => Self::TsIndexedAccessType(TsIndexedAccessType { syntax }),
            TS_INFER_TYPE => Self::TsInferType(TsInferType { syntax }),
            TS_INTERSECTION_TYPE => Self::TsIntersectionType(TsIntersectionType { syntax }),
            TS_MAPPED_TYPE => Self::TsMappedType(TsMappedType { syntax }),
            TS_NEVER_TYPE => Self::TsNeverType(TsNeverType { syntax }),
            TS_NON_PRIMITIVE_TYPE => Self::TsNonPrimitiveType(TsNonPrimitiveType { syntax }),
            TS_NULL_LITERAL_TYPE => Self::TsNullLiteralType(TsNullLiteralType { syntax }),
            TS_NUMBER_LITERAL_TYPE => Self::TsNumberLiteralType(TsNumberLiteralType { syntax }),
            TS_NUMBER_TYPE => Self::TsNumberType(TsNumberType { syntax }),
            TS_OBJECT_TYPE => Self::TsObjectType(TsObjectType { syntax }),
            TS_PARENTHESIZED_TYPE => Self::TsParenthesizedType(TsParenthesizedType { syntax }),
            TS_REFERENCE_TYPE => Self::TsReferenceType(TsReferenceType { syntax }),
            TS_STRING_LITERAL_TYPE => Self::TsStringLiteralType(TsStringLiteralType { syntax }),
            TS_STRING_TYPE => Self::TsStringType(TsStringType { syntax }),
            TS_SYMBOL_TYPE => Self::TsSymbolType(TsSymbolType { syntax }),
            TS_TEMPLATE_LITERAL_TYPE => {
                Self::TsTemplateLiteralType(TsTemplateLiteralType { syntax })
            }
            TS_THIS_TYPE => Self::TsThisType(TsThisType { syntax }),
            TS_TUPLE_TYPE => Self::TsTupleType(TsTupleType { syntax }),
            TS_TYPE_OPERATOR_TYPE => Self::TsTypeOperatorType(TsTypeOperatorType { syntax }),
            TS_TYPEOF_TYPE => Self::TsTypeofType(TsTypeofType { syntax }),
            TS_UNDEFINED_TYPE => Self::TsUndefinedType(TsUndefinedType { syntax }),
            TS_UNION_TYPE => Self::TsUnionType(TsUnionType { syntax }),
            TS_UNKNOWN_TYPE => Self::TsUnknownType(TsUnknownType { syntax }),
            TS_VOID_TYPE => Self::TsVoidType(TsVoidType { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.syntax(),
            Self::TsAnyType(it) => it.syntax(),
            Self::TsArrayType(it) => it.syntax(),
            Self::TsBigintLiteralType(it) => it.syntax(),
            Self::TsBigintType(it) => it.syntax(),
            Self::TsBogusType(it) => it.syntax(),
            Self::TsBooleanLiteralType(it) => it.syntax(),
            Self::TsBooleanType(it) => it.syntax(),
            Self::TsConditionalType(it) => it.syntax(),
            Self::TsConstructorType(it) => it.syntax(),
            Self::TsFunctionType(it) => it.syntax(),
            Self::TsImportType(it) => it.syntax(),
            Self::TsIndexedAccessType(it) => it.syntax(),
            Self::TsInferType(it) => it.syntax(),
            Self::TsIntersectionType(it) => it.syntax(),
            Self::TsMappedType(it) => it.syntax(),
            Self::TsNeverType(it) => it.syntax(),
            Self::TsNonPrimitiveType(it) => it.syntax(),
            Self::TsNullLiteralType(it) => it.syntax(),
            Self::TsNumberLiteralType(it) => it.syntax(),
            Self::TsNumberType(it) => it.syntax(),
            Self::TsObjectType(it) => it.syntax(),
            Self::TsParenthesizedType(it) => it.syntax(),
            Self::TsReferenceType(it) => it.syntax(),
            Self::TsStringLiteralType(it) => it.syntax(),
            Self::TsStringType(it) => it.syntax(),
            Self::TsSymbolType(it) => it.syntax(),
            Self::TsTemplateLiteralType(it) => it.syntax(),
            Self::TsThisType(it) => it.syntax(),
            Self::TsTupleType(it) => it.syntax(),
            Self::TsTypeOperatorType(it) => it.syntax(),
            Self::TsTypeofType(it) => it.syntax(),
            Self::TsUndefinedType(it) => it.syntax(),
            Self::TsUnionType(it) => it.syntax(),
            Self::TsUnknownType(it) => it.syntax(),
            Self::TsVoidType(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsMetavariable(it) => it.into_syntax(),
            Self::TsAnyType(it) => it.into_syntax(),
            Self::TsArrayType(it) => it.into_syntax(),
            Self::TsBigintLiteralType(it) => it.into_syntax(),
            Self::TsBigintType(it) => it.into_syntax(),
            Self::TsBogusType(it) => it.into_syntax(),
            Self::TsBooleanLiteralType(it) => it.into_syntax(),
            Self::TsBooleanType(it) => it.into_syntax(),
            Self::TsConditionalType(it) => it.into_syntax(),
            Self::TsConstructorType(it) => it.into_syntax(),
            Self::TsFunctionType(it) => it.into_syntax(),
            Self::TsImportType(it) => it.into_syntax(),
            Self::TsIndexedAccessType(it) => it.into_syntax(),
            Self::TsInferType(it) => it.into_syntax(),
            Self::TsIntersectionType(it) => it.into_syntax(),
            Self::TsMappedType(it) => it.into_syntax(),
            Self::TsNeverType(it) => it.into_syntax(),
            Self::TsNonPrimitiveType(it) => it.into_syntax(),
            Self::TsNullLiteralType(it) => it.into_syntax(),
            Self::TsNumberLiteralType(it) => it.into_syntax(),
            Self::TsNumberType(it) => it.into_syntax(),
            Self::TsObjectType(it) => it.into_syntax(),
            Self::TsParenthesizedType(it) => it.into_syntax(),
            Self::TsReferenceType(it) => it.into_syntax(),
            Self::TsStringLiteralType(it) => it.into_syntax(),
            Self::TsStringType(it) => it.into_syntax(),
            Self::TsSymbolType(it) => it.into_syntax(),
            Self::TsTemplateLiteralType(it) => it.into_syntax(),
            Self::TsThisType(it) => it.into_syntax(),
            Self::TsTupleType(it) => it.into_syntax(),
            Self::TsTypeOperatorType(it) => it.into_syntax(),
            Self::TsTypeofType(it) => it.into_syntax(),
            Self::TsUndefinedType(it) => it.into_syntax(),
            Self::TsUnionType(it) => it.into_syntax(),
            Self::TsUnknownType(it) => it.into_syntax(),
            Self::TsVoidType(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsMetavariable(it) => std::fmt::Debug::fmt(it, f),
            Self::TsAnyType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsArrayType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsBigintLiteralType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsBigintType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsBogusType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsBooleanLiteralType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsBooleanType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsConditionalType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsConstructorType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsFunctionType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsImportType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsIndexedAccessType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInferType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsIntersectionType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsMappedType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNeverType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNonPrimitiveType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNullLiteralType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNumberLiteralType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsNumberType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsObjectType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsParenthesizedType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsReferenceType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsStringLiteralType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsStringType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsSymbolType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTemplateLiteralType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsThisType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTupleType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeOperatorType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeofType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsUndefinedType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsUnionType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsUnknownType(it) => std::fmt::Debug::fmt(it, f),
            Self::TsVoidType(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsType> for SyntaxNode {
    fn from(n: AnyTsType) -> Self {
        match n {
            AnyTsType::JsMetavariable(it) => it.into_syntax(),
            AnyTsType::TsAnyType(it) => it.into_syntax(),
            AnyTsType::TsArrayType(it) => it.into_syntax(),
            AnyTsType::TsBigintLiteralType(it) => it.into_syntax(),
            AnyTsType::TsBigintType(it) => it.into_syntax(),
            AnyTsType::TsBogusType(it) => it.into_syntax(),
            AnyTsType::TsBooleanLiteralType(it) => it.into_syntax(),
            AnyTsType::TsBooleanType(it) => it.into_syntax(),
            AnyTsType::TsConditionalType(it) => it.into_syntax(),
            AnyTsType::TsConstructorType(it) => it.into_syntax(),
            AnyTsType::TsFunctionType(it) => it.into_syntax(),
            AnyTsType::TsImportType(it) => it.into_syntax(),
            AnyTsType::TsIndexedAccessType(it) => it.into_syntax(),
            AnyTsType::TsInferType(it) => it.into_syntax(),
            AnyTsType::TsIntersectionType(it) => it.into_syntax(),
            AnyTsType::TsMappedType(it) => it.into_syntax(),
            AnyTsType::TsNeverType(it) => it.into_syntax(),
            AnyTsType::TsNonPrimitiveType(it) => it.into_syntax(),
            AnyTsType::TsNullLiteralType(it) => it.into_syntax(),
            AnyTsType::TsNumberLiteralType(it) => it.into_syntax(),
            AnyTsType::TsNumberType(it) => it.into_syntax(),
            AnyTsType::TsObjectType(it) => it.into_syntax(),
            AnyTsType::TsParenthesizedType(it) => it.into_syntax(),
            AnyTsType::TsReferenceType(it) => it.into_syntax(),
            AnyTsType::TsStringLiteralType(it) => it.into_syntax(),
            AnyTsType::TsStringType(it) => it.into_syntax(),
            AnyTsType::TsSymbolType(it) => it.into_syntax(),
            AnyTsType::TsTemplateLiteralType(it) => it.into_syntax(),
            AnyTsType::TsThisType(it) => it.into_syntax(),
            AnyTsType::TsTupleType(it) => it.into_syntax(),
            AnyTsType::TsTypeOperatorType(it) => it.into_syntax(),
            AnyTsType::TsTypeofType(it) => it.into_syntax(),
            AnyTsType::TsUndefinedType(it) => it.into_syntax(),
            AnyTsType::TsUnionType(it) => it.into_syntax(),
            AnyTsType::TsUnknownType(it) => it.into_syntax(),
            AnyTsType::TsVoidType(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsType> for SyntaxElement {
    fn from(n: AnyTsType) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsBogusMember> for AnyTsTypeMember {
    fn from(node: JsBogusMember) -> Self {
        Self::JsBogusMember(node)
    }
}
impl From<TsCallSignatureTypeMember> for AnyTsTypeMember {
    fn from(node: TsCallSignatureTypeMember) -> Self {
        Self::TsCallSignatureTypeMember(node)
    }
}
impl From<TsConstructSignatureTypeMember> for AnyTsTypeMember {
    fn from(node: TsConstructSignatureTypeMember) -> Self {
        Self::TsConstructSignatureTypeMember(node)
    }
}
impl From<TsGetterSignatureTypeMember> for AnyTsTypeMember {
    fn from(node: TsGetterSignatureTypeMember) -> Self {
        Self::TsGetterSignatureTypeMember(node)
    }
}
impl From<TsIndexSignatureTypeMember> for AnyTsTypeMember {
    fn from(node: TsIndexSignatureTypeMember) -> Self {
        Self::TsIndexSignatureTypeMember(node)
    }
}
impl From<TsMethodSignatureTypeMember> for AnyTsTypeMember {
    fn from(node: TsMethodSignatureTypeMember) -> Self {
        Self::TsMethodSignatureTypeMember(node)
    }
}
impl From<TsPropertySignatureTypeMember> for AnyTsTypeMember {
    fn from(node: TsPropertySignatureTypeMember) -> Self {
        Self::TsPropertySignatureTypeMember(node)
    }
}
impl From<TsSetterSignatureTypeMember> for AnyTsTypeMember {
    fn from(node: TsSetterSignatureTypeMember) -> Self {
        Self::TsSetterSignatureTypeMember(node)
    }
}
impl AstNode for AnyTsTypeMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = JsBogusMember::KIND_SET
        .union(TsCallSignatureTypeMember::KIND_SET)
        .union(TsConstructSignatureTypeMember::KIND_SET)
        .union(TsGetterSignatureTypeMember::KIND_SET)
        .union(TsIndexSignatureTypeMember::KIND_SET)
        .union(TsMethodSignatureTypeMember::KIND_SET)
        .union(TsPropertySignatureTypeMember::KIND_SET)
        .union(TsSetterSignatureTypeMember::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(
            kind,
            JS_BOGUS_MEMBER
                | TS_CALL_SIGNATURE_TYPE_MEMBER
                | TS_CONSTRUCT_SIGNATURE_TYPE_MEMBER
                | TS_GETTER_SIGNATURE_TYPE_MEMBER
                | TS_INDEX_SIGNATURE_TYPE_MEMBER
                | TS_METHOD_SIGNATURE_TYPE_MEMBER
                | TS_PROPERTY_SIGNATURE_TYPE_MEMBER
                | TS_SETTER_SIGNATURE_TYPE_MEMBER
        )
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_BOGUS_MEMBER => Self::JsBogusMember(JsBogusMember { syntax }),
            TS_CALL_SIGNATURE_TYPE_MEMBER => {
                Self::TsCallSignatureTypeMember(TsCallSignatureTypeMember { syntax })
            }
            TS_CONSTRUCT_SIGNATURE_TYPE_MEMBER => {
                Self::TsConstructSignatureTypeMember(TsConstructSignatureTypeMember { syntax })
            }
            TS_GETTER_SIGNATURE_TYPE_MEMBER => {
                Self::TsGetterSignatureTypeMember(TsGetterSignatureTypeMember { syntax })
            }
            TS_INDEX_SIGNATURE_TYPE_MEMBER => {
                Self::TsIndexSignatureTypeMember(TsIndexSignatureTypeMember { syntax })
            }
            TS_METHOD_SIGNATURE_TYPE_MEMBER => {
                Self::TsMethodSignatureTypeMember(TsMethodSignatureTypeMember { syntax })
            }
            TS_PROPERTY_SIGNATURE_TYPE_MEMBER => {
                Self::TsPropertySignatureTypeMember(TsPropertySignatureTypeMember { syntax })
            }
            TS_SETTER_SIGNATURE_TYPE_MEMBER => {
                Self::TsSetterSignatureTypeMember(TsSetterSignatureTypeMember { syntax })
            }
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsBogusMember(it) => it.syntax(),
            Self::TsCallSignatureTypeMember(it) => it.syntax(),
            Self::TsConstructSignatureTypeMember(it) => it.syntax(),
            Self::TsGetterSignatureTypeMember(it) => it.syntax(),
            Self::TsIndexSignatureTypeMember(it) => it.syntax(),
            Self::TsMethodSignatureTypeMember(it) => it.syntax(),
            Self::TsPropertySignatureTypeMember(it) => it.syntax(),
            Self::TsSetterSignatureTypeMember(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsBogusMember(it) => it.into_syntax(),
            Self::TsCallSignatureTypeMember(it) => it.into_syntax(),
            Self::TsConstructSignatureTypeMember(it) => it.into_syntax(),
            Self::TsGetterSignatureTypeMember(it) => it.into_syntax(),
            Self::TsIndexSignatureTypeMember(it) => it.into_syntax(),
            Self::TsMethodSignatureTypeMember(it) => it.into_syntax(),
            Self::TsPropertySignatureTypeMember(it) => it.into_syntax(),
            Self::TsSetterSignatureTypeMember(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsBogusMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsCallSignatureTypeMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsConstructSignatureTypeMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsGetterSignatureTypeMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsIndexSignatureTypeMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsMethodSignatureTypeMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsPropertySignatureTypeMember(it) => std::fmt::Debug::fmt(it, f),
            Self::TsSetterSignatureTypeMember(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsTypeMember> for SyntaxNode {
    fn from(n: AnyTsTypeMember) -> Self {
        match n {
            AnyTsTypeMember::JsBogusMember(it) => it.into_syntax(),
            AnyTsTypeMember::TsCallSignatureTypeMember(it) => it.into_syntax(),
            AnyTsTypeMember::TsConstructSignatureTypeMember(it) => it.into_syntax(),
            AnyTsTypeMember::TsGetterSignatureTypeMember(it) => it.into_syntax(),
            AnyTsTypeMember::TsIndexSignatureTypeMember(it) => it.into_syntax(),
            AnyTsTypeMember::TsMethodSignatureTypeMember(it) => it.into_syntax(),
            AnyTsTypeMember::TsPropertySignatureTypeMember(it) => it.into_syntax(),
            AnyTsTypeMember::TsSetterSignatureTypeMember(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsTypeMember> for SyntaxElement {
    fn from(n: AnyTsTypeMember) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsConstModifier> for AnyTsTypeParameterModifier {
    fn from(node: TsConstModifier) -> Self {
        Self::TsConstModifier(node)
    }
}
impl From<TsInModifier> for AnyTsTypeParameterModifier {
    fn from(node: TsInModifier) -> Self {
        Self::TsInModifier(node)
    }
}
impl From<TsOutModifier> for AnyTsTypeParameterModifier {
    fn from(node: TsOutModifier) -> Self {
        Self::TsOutModifier(node)
    }
}
impl AstNode for AnyTsTypeParameterModifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = TsConstModifier::KIND_SET
        .union(TsInModifier::KIND_SET)
        .union(TsOutModifier::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, TS_CONST_MODIFIER | TS_IN_MODIFIER | TS_OUT_MODIFIER)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_CONST_MODIFIER => Self::TsConstModifier(TsConstModifier { syntax }),
            TS_IN_MODIFIER => Self::TsInModifier(TsInModifier { syntax }),
            TS_OUT_MODIFIER => Self::TsOutModifier(TsOutModifier { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsConstModifier(it) => it.syntax(),
            Self::TsInModifier(it) => it.syntax(),
            Self::TsOutModifier(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsConstModifier(it) => it.into_syntax(),
            Self::TsInModifier(it) => it.into_syntax(),
            Self::TsOutModifier(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsTypeParameterModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::TsConstModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsInModifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsOutModifier(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsTypeParameterModifier> for SyntaxNode {
    fn from(n: AnyTsTypeParameterModifier) -> Self {
        match n {
            AnyTsTypeParameterModifier::TsConstModifier(it) => it.into_syntax(),
            AnyTsTypeParameterModifier::TsInModifier(it) => it.into_syntax(),
            AnyTsTypeParameterModifier::TsOutModifier(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsTypeParameterModifier> for SyntaxElement {
    fn from(n: AnyTsTypeParameterModifier) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<JsReferenceIdentifier> for AnyTsTypePredicateParameterName {
    fn from(node: JsReferenceIdentifier) -> Self {
        Self::JsReferenceIdentifier(node)
    }
}
impl From<TsThisType> for AnyTsTypePredicateParameterName {
    fn from(node: TsThisType) -> Self {
        Self::TsThisType(node)
    }
}
impl AstNode for AnyTsTypePredicateParameterName {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        JsReferenceIdentifier::KIND_SET.union(TsThisType::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, JS_REFERENCE_IDENTIFIER | TS_THIS_TYPE)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            JS_REFERENCE_IDENTIFIER => {
                Self::JsReferenceIdentifier(JsReferenceIdentifier { syntax })
            }
            TS_THIS_TYPE => Self::TsThisType(TsThisType { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::JsReferenceIdentifier(it) => it.syntax(),
            Self::TsThisType(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::JsReferenceIdentifier(it) => it.into_syntax(),
            Self::TsThisType(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsTypePredicateParameterName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::JsReferenceIdentifier(it) => std::fmt::Debug::fmt(it, f),
            Self::TsThisType(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsTypePredicateParameterName> for SyntaxNode {
    fn from(n: AnyTsTypePredicateParameterName) -> Self {
        match n {
            AnyTsTypePredicateParameterName::JsReferenceIdentifier(it) => it.into_syntax(),
            AnyTsTypePredicateParameterName::TsThisType(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsTypePredicateParameterName> for SyntaxElement {
    fn from(n: AnyTsTypePredicateParameterName) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl From<TsDefiniteVariableAnnotation> for AnyTsVariableAnnotation {
    fn from(node: TsDefiniteVariableAnnotation) -> Self {
        Self::TsDefiniteVariableAnnotation(node)
    }
}
impl From<TsTypeAnnotation> for AnyTsVariableAnnotation {
    fn from(node: TsTypeAnnotation) -> Self {
        Self::TsTypeAnnotation(node)
    }
}
impl AstNode for AnyTsVariableAnnotation {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        TsDefiniteVariableAnnotation::KIND_SET.union(TsTypeAnnotation::KIND_SET);
    fn can_cast(kind: SyntaxKind) -> bool {
        matches!(kind, TS_DEFINITE_VARIABLE_ANNOTATION | TS_TYPE_ANNOTATION)
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        let res = match syntax.kind() {
            TS_DEFINITE_VARIABLE_ANNOTATION => {
                Self::TsDefiniteVariableAnnotation(TsDefiniteVariableAnnotation { syntax })
            }
            TS_TYPE_ANNOTATION => Self::TsTypeAnnotation(TsTypeAnnotation { syntax }),
            _ => return None,
        };
        Some(res)
    }
    fn syntax(&self) -> &SyntaxNode {
        match self {
            Self::TsDefiniteVariableAnnotation(it) => it.syntax(),
            Self::TsTypeAnnotation(it) => it.syntax(),
        }
    }
    fn into_syntax(self) -> SyntaxNode {
        match self {
            Self::TsDefiniteVariableAnnotation(it) => it.into_syntax(),
            Self::TsTypeAnnotation(it) => it.into_syntax(),
        }
    }
}
impl std::fmt::Debug for AnyTsVariableAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        match self {
            Self::TsDefiniteVariableAnnotation(it) => std::fmt::Debug::fmt(it, f),
            Self::TsTypeAnnotation(it) => std::fmt::Debug::fmt(it, f),
        }
    }
}
impl From<AnyTsVariableAnnotation> for SyntaxNode {
    fn from(n: AnyTsVariableAnnotation) -> Self {
        match n {
            AnyTsVariableAnnotation::TsDefiniteVariableAnnotation(it) => it.into_syntax(),
            AnyTsVariableAnnotation::TsTypeAnnotation(it) => it.into_syntax(),
        }
    }
}
impl From<AnyTsVariableAnnotation> for SyntaxElement {
    fn from(n: AnyTsVariableAnnotation) -> Self {
        let node: SyntaxNode = n.into();
        node.into()
    }
}
impl std::fmt::Display for AnyJsArrayAssignmentPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsArrayBindingPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsArrayElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsArrowFunctionParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsAssignmentPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsBindingPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsCallArgument {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsClass {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsClassMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsCombinedSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsConstructorParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsDeclarationClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsDecorator {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsExportClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsExportNamedSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsForInOrOfInitializer {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsForInitializer {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsFormalParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsFunction {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsFunctionBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsImportAssertionEntry {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsImportClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsInProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsMethodModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsModuleItem {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsModuleSource {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsNamedImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsObjectAssignmentPatternMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsObjectBindingPatternMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsObjectMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsPropertyModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsRoot {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsSwitchClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxAttribute {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxAttributeName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxAttributeValue {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxChild {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxElementName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxObjectName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyJsxTag {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsEnumMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsExternalModuleDeclarationBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsIdentifierBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsIndexSignatureModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsMethodSignatureModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsModuleName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsModuleReference {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsPropertyAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsPropertyParameterModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsPropertySignatureAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsPropertySignatureModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsReturnType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsTypeParameterModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsTypePredicateParameterName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for AnyTsVariableAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsAccessorModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayAssignmentPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayAssignmentPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayAssignmentPatternRestElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayBindingPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayBindingPatternElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayBindingPatternRestElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrayHole {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsArrowFunctionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsAssignmentExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsAwaitExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsBigintLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsBinaryExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsBlockStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsBooleanLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsBreakStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsCallArguments {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsCallExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsCaseClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsCatchClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsCatchDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsClassDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsClassExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsClassExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsComputedMemberAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsComputedMemberExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsComputedMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsConditionalExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsConstructorClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsConstructorParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsContinueStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsDebuggerStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsDecorator {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsDefaultClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsDefaultImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsDirective {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsDoWhileStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsElseClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsEmptyClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsEmptyStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExport {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportAsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportDefaultDeclarationClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportDefaultExpressionClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportFromClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportNamedClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportNamedFromClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportNamedFromSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportNamedShorthandSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExportNamedSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExpressionSnipped {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExpressionStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsExtendsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsFinallyClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsForInStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsForOfStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsForStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsForVariableDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsFormalParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsFunctionBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsFunctionDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsFunctionExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsFunctionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsGetterClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsGetterObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsIdentifierAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsIdentifierBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsIdentifierExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsIfStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImport {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportAssertion {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportAssertionEntry {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportBareClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportCallExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportCombinedClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportDefaultClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportMetaExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportNamedClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsImportNamespaceClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsInExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsInitializerClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsInstanceofExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsLabel {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsLabeledStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsLiteralExportName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsLiteralMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsLogicalExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsMetavariable {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsMethodClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsMethodObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsModule {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsModuleSource {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsNamedImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsNamedImportSpecifiers {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsNamespaceImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsNewExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsNewTargetExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsNullLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsNumberLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectAssignmentPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectAssignmentPatternProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectAssignmentPatternRest {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectAssignmentPatternShorthandProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectBindingPattern {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectBindingPatternProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectBindingPatternRest {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectBindingPatternShorthandProperty {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsObjectExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsParenthesizedAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsParenthesizedExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsPostUpdateExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsPreUpdateExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsPrivateClassMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsPrivateName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsPropertyClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsPropertyObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsReferenceIdentifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsRegexLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsRestParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsReturnStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsScript {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsSequenceExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsSetterClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsSetterObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsShorthandNamedImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsShorthandPropertyObjectMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsSpread {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsStaticInitializationBlockClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsStaticMemberAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsStaticMemberExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsStaticModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsStringLiteralExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsSuperExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsSwitchStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsTemplateChunkElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsTemplateExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsThisExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsThrowStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsTryFinallyStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsTryStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsUnaryExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsVariableDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsVariableDeclarationClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsVariableDeclarator {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsVariableStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsWhileStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsWithStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsYieldArgument {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsYieldExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxAttribute {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxAttributeInitializerClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxClosingElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxClosingFragment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxExpressionAttributeValue {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxExpressionChild {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxFragment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxNamespaceName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxOpeningElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxOpeningFragment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxReferenceIdentifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxSelfClosingElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxSpreadAttribute {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxSpreadChild {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxString {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxTagExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for JsxText {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsAbstractModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsAccessibilityModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsAnyType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsArrayType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsAsAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsAsExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsAssertsCondition {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsAssertsReturnType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsBigintLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsBigintType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsBooleanLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsBooleanType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsCallSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsConditionalType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsConstModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsConstructSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsConstructorSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsConstructorType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDeclarationModule {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDeclareFunctionDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDeclareFunctionExportDefaultDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDeclareModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDeclareStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDefaultTypeClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDefinitePropertyAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsDefiniteVariableAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsEmptyExternalModuleDeclarationBody {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsEnumDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsEnumMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsExportAsNamespaceClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsExportAssignmentClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsExportDeclareClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsExtendsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsExternalModuleDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsExternalModuleReference {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsFunctionType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsGetterSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsGetterSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsGlobalDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsIdentifierBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsImplementsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsImportEqualsDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsImportType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsImportTypeArguments {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsImportTypeAssertion {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsImportTypeAssertionBlock {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsImportTypeQualifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsInModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsIndexSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsIndexSignatureParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsIndexSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsIndexedAccessType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsInferType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsInitializedPropertySignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsInstantiationExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsInterfaceDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsIntersectionType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsLiteralEnumMemberName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsMappedType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsMappedTypeAsClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsMappedTypeOptionalModifierClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsMappedTypeReadonlyModifierClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsMethodSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsMethodSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsModuleBlock {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsModuleDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNamedTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNeverType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNonNullAssertionAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNonNullAssertionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNonPrimitiveType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNullLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNumberLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsNumberType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsObjectType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsOptionalPropertyAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsOptionalTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsOutModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsOverrideModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsParenthesizedType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsPredicateReturnType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsPropertyParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsPropertySignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsPropertySignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsQualifiedModuleName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsQualifiedName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsReadonlyModifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsReferenceType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsRestTupleTypeElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsReturnTypeAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsSatisfiesAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsSatisfiesExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsSetterSignatureClassMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsSetterSignatureTypeMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsStringLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsStringType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsSymbolType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTemplateChunkElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTemplateElement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTemplateLiteralType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsThisParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsThisType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTupleType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeAliasDeclaration {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeAnnotation {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeArguments {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeAssertionAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeAssertionExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeConstraintClause {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeOperatorType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeParameterName {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeParameters {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsTypeofType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsUndefinedType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsUnionType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsUnknownType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
impl std::fmt::Display for TsVoidType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        std::fmt::Display::fmt(self.syntax(), f)
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogus {
    syntax: SyntaxNode,
}
impl JsBogus {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogus {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogus {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogus")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogus> for SyntaxNode {
    fn from(n: JsBogus) -> Self {
        n.syntax
    }
}
impl From<JsBogus> for SyntaxElement {
    fn from(n: JsBogus) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusAssignment {
    syntax: SyntaxNode,
}
impl JsBogusAssignment {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusAssignment {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_ASSIGNMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_ASSIGNMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusAssignment {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusAssignment")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusAssignment> for SyntaxNode {
    fn from(n: JsBogusAssignment) -> Self {
        n.syntax
    }
}
impl From<JsBogusAssignment> for SyntaxElement {
    fn from(n: JsBogusAssignment) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusBinding {
    syntax: SyntaxNode,
}
impl JsBogusBinding {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusBinding {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_BINDING as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_BINDING
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusBinding {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusBinding")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusBinding> for SyntaxNode {
    fn from(n: JsBogusBinding) -> Self {
        n.syntax
    }
}
impl From<JsBogusBinding> for SyntaxElement {
    fn from(n: JsBogusBinding) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusExpression {
    syntax: SyntaxNode,
}
impl JsBogusExpression {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusExpression {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_EXPRESSION as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_EXPRESSION
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusExpression {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusExpression")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusExpression> for SyntaxNode {
    fn from(n: JsBogusExpression) -> Self {
        n.syntax
    }
}
impl From<JsBogusExpression> for SyntaxElement {
    fn from(n: JsBogusExpression) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusImportAssertionEntry {
    syntax: SyntaxNode,
}
impl JsBogusImportAssertionEntry {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusImportAssertionEntry {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_IMPORT_ASSERTION_ENTRY as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_IMPORT_ASSERTION_ENTRY
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusImportAssertionEntry {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusImportAssertionEntry")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusImportAssertionEntry> for SyntaxNode {
    fn from(n: JsBogusImportAssertionEntry) -> Self {
        n.syntax
    }
}
impl From<JsBogusImportAssertionEntry> for SyntaxElement {
    fn from(n: JsBogusImportAssertionEntry) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusMember {
    syntax: SyntaxNode,
}
impl JsBogusMember {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusMember {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_MEMBER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_MEMBER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusMember {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusMember")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusMember> for SyntaxNode {
    fn from(n: JsBogusMember) -> Self {
        n.syntax
    }
}
impl From<JsBogusMember> for SyntaxElement {
    fn from(n: JsBogusMember) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusNamedImportSpecifier {
    syntax: SyntaxNode,
}
impl JsBogusNamedImportSpecifier {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusNamedImportSpecifier {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_NAMED_IMPORT_SPECIFIER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_NAMED_IMPORT_SPECIFIER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusNamedImportSpecifier {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusNamedImportSpecifier")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusNamedImportSpecifier> for SyntaxNode {
    fn from(n: JsBogusNamedImportSpecifier) -> Self {
        n.syntax
    }
}
impl From<JsBogusNamedImportSpecifier> for SyntaxElement {
    fn from(n: JsBogusNamedImportSpecifier) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusParameter {
    syntax: SyntaxNode,
}
impl JsBogusParameter {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusParameter {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_PARAMETER as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_PARAMETER
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusParameter {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusParameter")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusParameter> for SyntaxNode {
    fn from(n: JsBogusParameter) -> Self {
        n.syntax
    }
}
impl From<JsBogusParameter> for SyntaxElement {
    fn from(n: JsBogusParameter) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct JsBogusStatement {
    syntax: SyntaxNode,
}
impl JsBogusStatement {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for JsBogusStatement {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_BOGUS_STATEMENT as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_BOGUS_STATEMENT
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for JsBogusStatement {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("JsBogusStatement")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<JsBogusStatement> for SyntaxNode {
    fn from(n: JsBogusStatement) -> Self {
        n.syntax
    }
}
impl From<JsBogusStatement> for SyntaxElement {
    fn from(n: JsBogusStatement) -> Self {
        n.syntax.into()
    }
}
#[derive(Clone, PartialEq, Eq, Hash, Serialize)]
pub struct TsBogusType {
    syntax: SyntaxNode,
}
impl TsBogusType {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub const unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self { syntax }
    }
    pub fn items(&self) -> SyntaxElementChildren {
        support::elements(&self.syntax)
    }
}
impl AstNode for TsBogusType {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_BOGUS_TYPE as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_BOGUS_TYPE
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self { syntax })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        &self.syntax
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax
    }
}
impl std::fmt::Debug for TsBogusType {
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
        f.debug_struct("TsBogusType")
            .field("items", &DebugSyntaxElementChildren(self.items()))
            .finish()
    }
}
impl From<TsBogusType> for SyntaxNode {
    fn from(n: TsBogusType) -> Self {
        n.syntax
    }
}
impl From<TsBogusType> for SyntaxElement {
    fn from(n: TsBogusType) -> Self {
        n.syntax.into()
    }
}
biome_rowan::declare_node_union! { pub AnyJsBogusNode = JsBogus | JsBogusAssignment | JsBogusBinding | JsBogusExpression | JsBogusImportAssertionEntry | JsBogusMember | JsBogusNamedImportSpecifier | JsBogusParameter | JsBogusStatement | TsBogusType }
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsArrayAssignmentPatternElementList {
    syntax_list: SyntaxList,
}
impl JsArrayAssignmentPatternElementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsArrayAssignmentPatternElementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        JS_ARRAY_ASSIGNMENT_PATTERN_ELEMENT_LIST as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_ASSIGNMENT_PATTERN_ELEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsArrayAssignmentPatternElementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsArrayAssignmentPatternElementList {
    type Language = Language;
    type Node = AnyJsArrayAssignmentPatternElement;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsArrayAssignmentPatternElementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsArrayAssignmentPatternElementList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsArrayAssignmentPatternElementList {
    type Item = SyntaxResult<AnyJsArrayAssignmentPatternElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsArrayAssignmentPatternElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsArrayAssignmentPatternElementList {
    type Item = SyntaxResult<AnyJsArrayAssignmentPatternElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsArrayAssignmentPatternElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsArrayBindingPatternElementList {
    syntax_list: SyntaxList,
}
impl JsArrayBindingPatternElementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsArrayBindingPatternElementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_BINDING_PATTERN_ELEMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_BINDING_PATTERN_ELEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsArrayBindingPatternElementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsArrayBindingPatternElementList {
    type Language = Language;
    type Node = AnyJsArrayBindingPatternElement;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsArrayBindingPatternElementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsArrayBindingPatternElementList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsArrayBindingPatternElementList {
    type Item = SyntaxResult<AnyJsArrayBindingPatternElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsArrayBindingPatternElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsArrayBindingPatternElementList {
    type Item = SyntaxResult<AnyJsArrayBindingPatternElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsArrayBindingPatternElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsArrayElementList {
    syntax_list: SyntaxList,
}
impl JsArrayElementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsArrayElementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_ARRAY_ELEMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_ARRAY_ELEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsArrayElementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsArrayElementList {
    type Language = Language;
    type Node = AnyJsArrayElement;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsArrayElementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsArrayElementList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsArrayElementList {
    type Item = SyntaxResult<AnyJsArrayElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsArrayElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsArrayElementList {
    type Item = SyntaxResult<AnyJsArrayElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsArrayElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsCallArgumentList {
    syntax_list: SyntaxList,
}
impl JsCallArgumentList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsCallArgumentList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CALL_ARGUMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CALL_ARGUMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsCallArgumentList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsCallArgumentList {
    type Language = Language;
    type Node = AnyJsCallArgument;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsCallArgumentList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsCallArgumentList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsCallArgumentList {
    type Item = SyntaxResult<AnyJsCallArgument>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsCallArgument>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsCallArgumentList {
    type Item = SyntaxResult<AnyJsCallArgument>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsCallArgument>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsClassMemberList {
    syntax_list: SyntaxList,
}
impl JsClassMemberList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsClassMemberList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CLASS_MEMBER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CLASS_MEMBER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsClassMemberList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsClassMemberList {
    type Language = Language;
    type Node = AnyJsClassMember;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsClassMemberList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsClassMemberList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsClassMemberList {
    type Item = AnyJsClassMember;
    type IntoIter = AstNodeListIterator<Language, AnyJsClassMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsClassMemberList {
    type Item = AnyJsClassMember;
    type IntoIter = AstNodeListIterator<Language, AnyJsClassMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsConstructorModifierList {
    syntax_list: SyntaxList,
}
impl JsConstructorModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsConstructorModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CONSTRUCTOR_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CONSTRUCTOR_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsConstructorModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsConstructorModifierList {
    type Language = Language;
    type Node = TsAccessibilityModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsConstructorModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsConstructorModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsConstructorModifierList {
    type Item = TsAccessibilityModifier;
    type IntoIter = AstNodeListIterator<Language, TsAccessibilityModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsConstructorModifierList {
    type Item = TsAccessibilityModifier;
    type IntoIter = AstNodeListIterator<Language, TsAccessibilityModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsConstructorParameterList {
    syntax_list: SyntaxList,
}
impl JsConstructorParameterList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsConstructorParameterList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_CONSTRUCTOR_PARAMETER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_CONSTRUCTOR_PARAMETER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsConstructorParameterList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsConstructorParameterList {
    type Language = Language;
    type Node = AnyJsConstructorParameter;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsConstructorParameterList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsConstructorParameterList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsConstructorParameterList {
    type Item = SyntaxResult<AnyJsConstructorParameter>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsConstructorParameter>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsConstructorParameterList {
    type Item = SyntaxResult<AnyJsConstructorParameter>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsConstructorParameter>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsDecoratorList {
    syntax_list: SyntaxList,
}
impl JsDecoratorList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsDecoratorList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DECORATOR_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DECORATOR_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsDecoratorList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsDecoratorList {
    type Language = Language;
    type Node = JsDecorator;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsDecoratorList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsDecoratorList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsDecoratorList {
    type Item = JsDecorator;
    type IntoIter = AstNodeListIterator<Language, JsDecorator>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsDecoratorList {
    type Item = JsDecorator;
    type IntoIter = AstNodeListIterator<Language, JsDecorator>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsDirectiveList {
    syntax_list: SyntaxList,
}
impl JsDirectiveList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsDirectiveList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_DIRECTIVE_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_DIRECTIVE_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsDirectiveList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsDirectiveList {
    type Language = Language;
    type Node = JsDirective;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsDirectiveList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsDirectiveList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsDirectiveList {
    type Item = JsDirective;
    type IntoIter = AstNodeListIterator<Language, JsDirective>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsDirectiveList {
    type Item = JsDirective;
    type IntoIter = AstNodeListIterator<Language, JsDirective>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsExportNamedFromSpecifierList {
    syntax_list: SyntaxList,
}
impl JsExportNamedFromSpecifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsExportNamedFromSpecifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_NAMED_FROM_SPECIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_NAMED_FROM_SPECIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsExportNamedFromSpecifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsExportNamedFromSpecifierList {
    type Language = Language;
    type Node = JsExportNamedFromSpecifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsExportNamedFromSpecifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsExportNamedFromSpecifierList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsExportNamedFromSpecifierList {
    type Item = SyntaxResult<JsExportNamedFromSpecifier>;
    type IntoIter = AstSeparatedListNodesIterator<Language, JsExportNamedFromSpecifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsExportNamedFromSpecifierList {
    type Item = SyntaxResult<JsExportNamedFromSpecifier>;
    type IntoIter = AstSeparatedListNodesIterator<Language, JsExportNamedFromSpecifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsExportNamedSpecifierList {
    syntax_list: SyntaxList,
}
impl JsExportNamedSpecifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsExportNamedSpecifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_EXPORT_NAMED_SPECIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_EXPORT_NAMED_SPECIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsExportNamedSpecifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsExportNamedSpecifierList {
    type Language = Language;
    type Node = AnyJsExportNamedSpecifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsExportNamedSpecifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsExportNamedSpecifierList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsExportNamedSpecifierList {
    type Item = SyntaxResult<AnyJsExportNamedSpecifier>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsExportNamedSpecifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsExportNamedSpecifierList {
    type Item = SyntaxResult<AnyJsExportNamedSpecifier>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsExportNamedSpecifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsImportAssertionEntryList {
    syntax_list: SyntaxList,
}
impl JsImportAssertionEntryList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsImportAssertionEntryList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_IMPORT_ASSERTION_ENTRY_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_IMPORT_ASSERTION_ENTRY_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsImportAssertionEntryList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsImportAssertionEntryList {
    type Language = Language;
    type Node = AnyJsImportAssertionEntry;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsImportAssertionEntryList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsImportAssertionEntryList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsImportAssertionEntryList {
    type Item = SyntaxResult<AnyJsImportAssertionEntry>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsImportAssertionEntry>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsImportAssertionEntryList {
    type Item = SyntaxResult<AnyJsImportAssertionEntry>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsImportAssertionEntry>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsMethodModifierList {
    syntax_list: SyntaxList,
}
impl JsMethodModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsMethodModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_METHOD_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_METHOD_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsMethodModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsMethodModifierList {
    type Language = Language;
    type Node = AnyJsMethodModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsMethodModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsMethodModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsMethodModifierList {
    type Item = AnyJsMethodModifier;
    type IntoIter = AstNodeListIterator<Language, AnyJsMethodModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsMethodModifierList {
    type Item = AnyJsMethodModifier;
    type IntoIter = AstNodeListIterator<Language, AnyJsMethodModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsModuleItemList {
    syntax_list: SyntaxList,
}
impl JsModuleItemList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsModuleItemList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_MODULE_ITEM_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_MODULE_ITEM_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsModuleItemList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsModuleItemList {
    type Language = Language;
    type Node = AnyJsModuleItem;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsModuleItemList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsModuleItemList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsModuleItemList {
    type Item = AnyJsModuleItem;
    type IntoIter = AstNodeListIterator<Language, AnyJsModuleItem>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsModuleItemList {
    type Item = AnyJsModuleItem;
    type IntoIter = AstNodeListIterator<Language, AnyJsModuleItem>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsNamedImportSpecifierList {
    syntax_list: SyntaxList,
}
impl JsNamedImportSpecifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsNamedImportSpecifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_NAMED_IMPORT_SPECIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_NAMED_IMPORT_SPECIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsNamedImportSpecifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsNamedImportSpecifierList {
    type Language = Language;
    type Node = AnyJsNamedImportSpecifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsNamedImportSpecifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsNamedImportSpecifierList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsNamedImportSpecifierList {
    type Item = SyntaxResult<AnyJsNamedImportSpecifier>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsNamedImportSpecifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsNamedImportSpecifierList {
    type Item = SyntaxResult<AnyJsNamedImportSpecifier>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsNamedImportSpecifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsObjectAssignmentPatternPropertyList {
    syntax_list: SyntaxList,
}
impl JsObjectAssignmentPatternPropertyList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsObjectAssignmentPatternPropertyList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        JS_OBJECT_ASSIGNMENT_PATTERN_PROPERTY_LIST as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_ASSIGNMENT_PATTERN_PROPERTY_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsObjectAssignmentPatternPropertyList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsObjectAssignmentPatternPropertyList {
    type Language = Language;
    type Node = AnyJsObjectAssignmentPatternMember;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsObjectAssignmentPatternPropertyList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsObjectAssignmentPatternPropertyList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsObjectAssignmentPatternPropertyList {
    type Item = SyntaxResult<AnyJsObjectAssignmentPatternMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsObjectAssignmentPatternMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsObjectAssignmentPatternPropertyList {
    type Item = SyntaxResult<AnyJsObjectAssignmentPatternMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsObjectAssignmentPatternMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsObjectBindingPatternPropertyList {
    syntax_list: SyntaxList,
}
impl JsObjectBindingPatternPropertyList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsObjectBindingPatternPropertyList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> = SyntaxKindSet::from_raw(RawSyntaxKind(
        JS_OBJECT_BINDING_PATTERN_PROPERTY_LIST as u16,
    ));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_BINDING_PATTERN_PROPERTY_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsObjectBindingPatternPropertyList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsObjectBindingPatternPropertyList {
    type Language = Language;
    type Node = AnyJsObjectBindingPatternMember;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsObjectBindingPatternPropertyList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsObjectBindingPatternPropertyList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsObjectBindingPatternPropertyList {
    type Item = SyntaxResult<AnyJsObjectBindingPatternMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsObjectBindingPatternMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsObjectBindingPatternPropertyList {
    type Item = SyntaxResult<AnyJsObjectBindingPatternMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsObjectBindingPatternMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsObjectMemberList {
    syntax_list: SyntaxList,
}
impl JsObjectMemberList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsObjectMemberList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_OBJECT_MEMBER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_OBJECT_MEMBER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsObjectMemberList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsObjectMemberList {
    type Language = Language;
    type Node = AnyJsObjectMember;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsObjectMemberList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsObjectMemberList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsObjectMemberList {
    type Item = SyntaxResult<AnyJsObjectMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsObjectMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsObjectMemberList {
    type Item = SyntaxResult<AnyJsObjectMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsObjectMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsParameterList {
    syntax_list: SyntaxList,
}
impl JsParameterList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsParameterList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PARAMETER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PARAMETER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsParameterList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsParameterList {
    type Language = Language;
    type Node = AnyJsParameter;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsParameterList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsParameterList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsParameterList {
    type Item = SyntaxResult<AnyJsParameter>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsParameter>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsParameterList {
    type Item = SyntaxResult<AnyJsParameter>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyJsParameter>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsPropertyModifierList {
    syntax_list: SyntaxList,
}
impl JsPropertyModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsPropertyModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_PROPERTY_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_PROPERTY_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsPropertyModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsPropertyModifierList {
    type Language = Language;
    type Node = AnyJsPropertyModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsPropertyModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsPropertyModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsPropertyModifierList {
    type Item = AnyJsPropertyModifier;
    type IntoIter = AstNodeListIterator<Language, AnyJsPropertyModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsPropertyModifierList {
    type Item = AnyJsPropertyModifier;
    type IntoIter = AstNodeListIterator<Language, AnyJsPropertyModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsStatementList {
    syntax_list: SyntaxList,
}
impl JsStatementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsStatementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_STATEMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_STATEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsStatementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsStatementList {
    type Language = Language;
    type Node = AnyJsStatement;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsStatementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsStatementList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsStatementList {
    type Item = AnyJsStatement;
    type IntoIter = AstNodeListIterator<Language, AnyJsStatement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsStatementList {
    type Item = AnyJsStatement;
    type IntoIter = AstNodeListIterator<Language, AnyJsStatement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsSwitchCaseList {
    syntax_list: SyntaxList,
}
impl JsSwitchCaseList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsSwitchCaseList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_SWITCH_CASE_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_SWITCH_CASE_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsSwitchCaseList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsSwitchCaseList {
    type Language = Language;
    type Node = AnyJsSwitchClause;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsSwitchCaseList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsSwitchCaseList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsSwitchCaseList {
    type Item = AnyJsSwitchClause;
    type IntoIter = AstNodeListIterator<Language, AnyJsSwitchClause>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsSwitchCaseList {
    type Item = AnyJsSwitchClause;
    type IntoIter = AstNodeListIterator<Language, AnyJsSwitchClause>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsTemplateElementList {
    syntax_list: SyntaxList,
}
impl JsTemplateElementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsTemplateElementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_TEMPLATE_ELEMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_TEMPLATE_ELEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsTemplateElementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsTemplateElementList {
    type Language = Language;
    type Node = AnyJsTemplateElement;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsTemplateElementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsTemplateElementList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsTemplateElementList {
    type Item = AnyJsTemplateElement;
    type IntoIter = AstNodeListIterator<Language, AnyJsTemplateElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsTemplateElementList {
    type Item = AnyJsTemplateElement;
    type IntoIter = AstNodeListIterator<Language, AnyJsTemplateElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsVariableDeclaratorList {
    syntax_list: SyntaxList,
}
impl JsVariableDeclaratorList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsVariableDeclaratorList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JS_VARIABLE_DECLARATOR_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JS_VARIABLE_DECLARATOR_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsVariableDeclaratorList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for JsVariableDeclaratorList {
    type Language = Language;
    type Node = JsVariableDeclarator;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsVariableDeclaratorList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsVariableDeclaratorList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for JsVariableDeclaratorList {
    type Item = SyntaxResult<JsVariableDeclarator>;
    type IntoIter = AstSeparatedListNodesIterator<Language, JsVariableDeclarator>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &JsVariableDeclaratorList {
    type Item = SyntaxResult<JsVariableDeclarator>;
    type IntoIter = AstSeparatedListNodesIterator<Language, JsVariableDeclarator>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsxAttributeList {
    syntax_list: SyntaxList,
}
impl JsxAttributeList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsxAttributeList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_ATTRIBUTE_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_ATTRIBUTE_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsxAttributeList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsxAttributeList {
    type Language = Language;
    type Node = AnyJsxAttribute;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsxAttributeList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsxAttributeList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsxAttributeList {
    type Item = AnyJsxAttribute;
    type IntoIter = AstNodeListIterator<Language, AnyJsxAttribute>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsxAttributeList {
    type Item = AnyJsxAttribute;
    type IntoIter = AstNodeListIterator<Language, AnyJsxAttribute>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct JsxChildList {
    syntax_list: SyntaxList,
}
impl JsxChildList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for JsxChildList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(JSX_CHILD_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == JSX_CHILD_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for JsxChildList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for JsxChildList {
    type Language = Language;
    type Node = AnyJsxChild;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for JsxChildList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("JsxChildList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &JsxChildList {
    type Item = AnyJsxChild;
    type IntoIter = AstNodeListIterator<Language, AnyJsxChild>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for JsxChildList {
    type Item = AnyJsxChild;
    type IntoIter = AstNodeListIterator<Language, AnyJsxChild>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsEnumMemberList {
    syntax_list: SyntaxList,
}
impl TsEnumMemberList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsEnumMemberList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_ENUM_MEMBER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_ENUM_MEMBER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsEnumMemberList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for TsEnumMemberList {
    type Language = Language;
    type Node = TsEnumMember;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsEnumMemberList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsEnumMemberList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for TsEnumMemberList {
    type Item = SyntaxResult<TsEnumMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, TsEnumMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &TsEnumMemberList {
    type Item = SyntaxResult<TsEnumMember>;
    type IntoIter = AstSeparatedListNodesIterator<Language, TsEnumMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsIndexSignatureModifierList {
    syntax_list: SyntaxList,
}
impl TsIndexSignatureModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsIndexSignatureModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INDEX_SIGNATURE_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INDEX_SIGNATURE_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsIndexSignatureModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for TsIndexSignatureModifierList {
    type Language = Language;
    type Node = AnyTsIndexSignatureModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsIndexSignatureModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsIndexSignatureModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &TsIndexSignatureModifierList {
    type Item = AnyTsIndexSignatureModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsIndexSignatureModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for TsIndexSignatureModifierList {
    type Item = AnyTsIndexSignatureModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsIndexSignatureModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsIntersectionTypeElementList {
    syntax_list: SyntaxList,
}
impl TsIntersectionTypeElementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsIntersectionTypeElementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_INTERSECTION_TYPE_ELEMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_INTERSECTION_TYPE_ELEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsIntersectionTypeElementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for TsIntersectionTypeElementList {
    type Language = Language;
    type Node = AnyTsType;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsIntersectionTypeElementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsIntersectionTypeElementList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for TsIntersectionTypeElementList {
    type Item = SyntaxResult<AnyTsType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &TsIntersectionTypeElementList {
    type Item = SyntaxResult<AnyTsType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsMethodSignatureModifierList {
    syntax_list: SyntaxList,
}
impl TsMethodSignatureModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsMethodSignatureModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_METHOD_SIGNATURE_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_METHOD_SIGNATURE_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsMethodSignatureModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for TsMethodSignatureModifierList {
    type Language = Language;
    type Node = AnyTsMethodSignatureModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsMethodSignatureModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsMethodSignatureModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &TsMethodSignatureModifierList {
    type Item = AnyTsMethodSignatureModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsMethodSignatureModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for TsMethodSignatureModifierList {
    type Item = AnyTsMethodSignatureModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsMethodSignatureModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsPropertyParameterModifierList {
    syntax_list: SyntaxList,
}
impl TsPropertyParameterModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsPropertyParameterModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_PROPERTY_PARAMETER_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_PROPERTY_PARAMETER_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsPropertyParameterModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for TsPropertyParameterModifierList {
    type Language = Language;
    type Node = AnyTsPropertyParameterModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsPropertyParameterModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsPropertyParameterModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &TsPropertyParameterModifierList {
    type Item = AnyTsPropertyParameterModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsPropertyParameterModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for TsPropertyParameterModifierList {
    type Item = AnyTsPropertyParameterModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsPropertyParameterModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsPropertySignatureModifierList {
    syntax_list: SyntaxList,
}
impl TsPropertySignatureModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsPropertySignatureModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_PROPERTY_SIGNATURE_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_PROPERTY_SIGNATURE_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsPropertySignatureModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for TsPropertySignatureModifierList {
    type Language = Language;
    type Node = AnyTsPropertySignatureModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsPropertySignatureModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsPropertySignatureModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &TsPropertySignatureModifierList {
    type Item = AnyTsPropertySignatureModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsPropertySignatureModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for TsPropertySignatureModifierList {
    type Item = AnyTsPropertySignatureModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsPropertySignatureModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsTemplateElementList {
    syntax_list: SyntaxList,
}
impl TsTemplateElementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsTemplateElementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TEMPLATE_ELEMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TEMPLATE_ELEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsTemplateElementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for TsTemplateElementList {
    type Language = Language;
    type Node = AnyTsTemplateElement;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsTemplateElementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsTemplateElementList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &TsTemplateElementList {
    type Item = AnyTsTemplateElement;
    type IntoIter = AstNodeListIterator<Language, AnyTsTemplateElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for TsTemplateElementList {
    type Item = AnyTsTemplateElement;
    type IntoIter = AstNodeListIterator<Language, AnyTsTemplateElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsTupleTypeElementList {
    syntax_list: SyntaxList,
}
impl TsTupleTypeElementList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsTupleTypeElementList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TUPLE_TYPE_ELEMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TUPLE_TYPE_ELEMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsTupleTypeElementList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for TsTupleTypeElementList {
    type Language = Language;
    type Node = AnyTsTupleTypeElement;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsTupleTypeElementList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsTupleTypeElementList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for TsTupleTypeElementList {
    type Item = SyntaxResult<AnyTsTupleTypeElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsTupleTypeElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &TsTupleTypeElementList {
    type Item = SyntaxResult<AnyTsTupleTypeElement>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsTupleTypeElement>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsTypeArgumentList {
    syntax_list: SyntaxList,
}
impl TsTypeArgumentList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsTypeArgumentList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_ARGUMENT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_ARGUMENT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsTypeArgumentList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for TsTypeArgumentList {
    type Language = Language;
    type Node = AnyTsType;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsTypeArgumentList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsTypeArgumentList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for TsTypeArgumentList {
    type Item = SyntaxResult<AnyTsType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &TsTypeArgumentList {
    type Item = SyntaxResult<AnyTsType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsTypeList {
    syntax_list: SyntaxList,
}
impl TsTypeList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsTypeList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsTypeList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for TsTypeList {
    type Language = Language;
    type Node = TsReferenceType;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsTypeList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsTypeList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for TsTypeList {
    type Item = SyntaxResult<TsReferenceType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, TsReferenceType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &TsTypeList {
    type Item = SyntaxResult<TsReferenceType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, TsReferenceType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsTypeMemberList {
    syntax_list: SyntaxList,
}
impl TsTypeMemberList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsTypeMemberList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_MEMBER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_MEMBER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsTypeMemberList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for TsTypeMemberList {
    type Language = Language;
    type Node = AnyTsTypeMember;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsTypeMemberList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsTypeMemberList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &TsTypeMemberList {
    type Item = AnyTsTypeMember;
    type IntoIter = AstNodeListIterator<Language, AnyTsTypeMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for TsTypeMemberList {
    type Item = AnyTsTypeMember;
    type IntoIter = AstNodeListIterator<Language, AnyTsTypeMember>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsTypeParameterList {
    syntax_list: SyntaxList,
}
impl TsTypeParameterList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsTypeParameterList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_PARAMETER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_PARAMETER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsTypeParameterList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for TsTypeParameterList {
    type Language = Language;
    type Node = TsTypeParameter;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsTypeParameterList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsTypeParameterList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for TsTypeParameterList {
    type Item = SyntaxResult<TsTypeParameter>;
    type IntoIter = AstSeparatedListNodesIterator<Language, TsTypeParameter>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &TsTypeParameterList {
    type Item = SyntaxResult<TsTypeParameter>;
    type IntoIter = AstSeparatedListNodesIterator<Language, TsTypeParameter>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsTypeParameterModifierList {
    syntax_list: SyntaxList,
}
impl TsTypeParameterModifierList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsTypeParameterModifierList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_TYPE_PARAMETER_MODIFIER_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_TYPE_PARAMETER_MODIFIER_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsTypeParameterModifierList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstNodeList for TsTypeParameterModifierList {
    type Language = Language;
    type Node = AnyTsTypeParameterModifier;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsTypeParameterModifierList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsTypeParameterModifierList ")?;
        f.debug_list().entries(self.iter()).finish()
    }
}
impl IntoIterator for &TsTypeParameterModifierList {
    type Item = AnyTsTypeParameterModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsTypeParameterModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for TsTypeParameterModifierList {
    type Item = AnyTsTypeParameterModifier;
    type IntoIter = AstNodeListIterator<Language, AnyTsTypeParameterModifier>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone, Eq, PartialEq, Hash)]
pub struct TsUnionTypeVariantList {
    syntax_list: SyntaxList,
}
impl TsUnionTypeVariantList {
    #[doc = r" Create an AstNode from a SyntaxNode without checking its kind"]
    #[doc = r""]
    #[doc = r" # Safety"]
    #[doc = r" This function must be guarded with a call to [AstNode::can_cast]"]
    #[doc = r" or a match on [SyntaxNode::kind]"]
    #[inline]
    pub unsafe fn new_unchecked(syntax: SyntaxNode) -> Self {
        Self {
            syntax_list: syntax.into_list(),
        }
    }
}
impl AstNode for TsUnionTypeVariantList {
    type Language = Language;
    const KIND_SET: SyntaxKindSet<Language> =
        SyntaxKindSet::from_raw(RawSyntaxKind(TS_UNION_TYPE_VARIANT_LIST as u16));
    fn can_cast(kind: SyntaxKind) -> bool {
        kind == TS_UNION_TYPE_VARIANT_LIST
    }
    fn cast(syntax: SyntaxNode) -> Option<Self> {
        if Self::can_cast(syntax.kind()) {
            Some(Self {
                syntax_list: syntax.into_list(),
            })
        } else {
            None
        }
    }
    fn syntax(&self) -> &SyntaxNode {
        self.syntax_list.node()
    }
    fn into_syntax(self) -> SyntaxNode {
        self.syntax_list.into_node()
    }
}
impl Serialize for TsUnionTypeVariantList {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where
        S: Serializer,
    {
        let mut seq = serializer.serialize_seq(Some(self.len()))?;
        for e in self.iter() {
            seq.serialize_element(&e)?;
        }
        seq.end()
    }
}
impl AstSeparatedList for TsUnionTypeVariantList {
    type Language = Language;
    type Node = AnyTsType;
    fn syntax_list(&self) -> &SyntaxList {
        &self.syntax_list
    }
    fn into_syntax_list(self) -> SyntaxList {
        self.syntax_list
    }
}
impl Debug for TsUnionTypeVariantList {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.write_str("TsUnionTypeVariantList ")?;
        f.debug_list().entries(self.elements()).finish()
    }
}
impl IntoIterator for TsUnionTypeVariantList {
    type Item = SyntaxResult<AnyTsType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
impl IntoIterator for &TsUnionTypeVariantList {
    type Item = SyntaxResult<AnyTsType>;
    type IntoIter = AstSeparatedListNodesIterator<Language, AnyTsType>;
    fn into_iter(self) -> Self::IntoIter {
        self.iter()
    }
}
#[derive(Clone)]
pub struct DebugSyntaxElementChildren(pub SyntaxElementChildren);
impl Debug for DebugSyntaxElementChildren {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        f.debug_list()
            .entries(self.clone().0.map(DebugSyntaxElement))
            .finish()
    }
}
struct DebugSyntaxElement(SyntaxElement);
impl Debug for DebugSyntaxElement {
    fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
        match &self.0 {
            SyntaxElement::Node(node) => {
                map_syntax_node ! (node . clone () , node => std :: fmt :: Debug :: fmt (& node , f))
            }
            SyntaxElement::Token(token) => Debug::fmt(token, f),
        }
    }
}
