Global Variables

The following global variables are available globally.

  • Parser that matches all the whitespace characters.

    Matches the character set containing the characters in Unicode General Category Zs and CHARACTER TABULATION (U+0009).

    Declaration

    Swift

    public let whitespace: Parser<Character, Character>
  • Parser that matches all the newline characters.

    Matches the character set containing the newline characters (U+000A ~ U+000D, U+0085, U+2028, and U+2029).

    Declaration

    Swift

    public let newline: Parser<Character, Character>
  • Parser that matches all the whitespace and newline characters.

    Matches the character set containing characters in Unicode General Category Z*, U+000A ~ U+000D, and U+0085.

    Declaration

    Swift

    public let whitespacesOrNewline: Parser<Character, Character>
  • Parser that matches all the decimal digit characters.

    Matches the character set containing the characters in the category of Decimal Numbers.

    Declaration

    Swift

    public let digit: Parser<Character, Character>
  • Parser that matches all the alphanumeric characters.

    Matches the character set containing the characters in Unicode General Categories L*, M*, and N*.

    Declaration

    Swift

    public let alphanumeric: Parser<Character, Character>