Terminal

public protocol Terminal : Rule

Undocumented

  • Tests the the Terminal is available at the current scanner head position, throwing an Error if not

    Declaration

    Swift

    func test(lexer: LexicalAnalyzer, producing token: TokenType?) throws

    Parameters

    lexer

    The lexer being used for scanning

    token

    The token produced if any.

  • Provides a textual description of the match

    Declaration

    Swift

    var matchDescription: String { get }