Class TokenParser

Parses tokens in to expressions

Hierarchy

  • TokenParser

Implements

Constructors

Properties

#current: number = 0
tokens: Token[]

Methods

  • Check if the current token is of the expected token type

    Parameters

    • tokenType: TokenType

      The token type to check for

    Returns boolean

    Result of the check

  • Check if the next token is of the expected token type

    Parameters

    • tokenType: TokenType

      The token type to check for

    Returns boolean

    Result of the check

  • Move to the next token if current token is of the expected token type

    Parameters

    • tokenType: TokenType

      The token type to check for

    Returns boolean

    Result of the check

Generated using TypeDoc