stripQuotes : SnocList Char -> String- Visibility: public export
ltrim : List Char -> List Char- Visibility: export
countHashtag : List Char -> Nat- Visibility: export
rtrim : SnocList Char -> SnocList Char- Visibility: export
dropHead : Nat -> SnocList Char -> List Char- Visibility: export
countHashtag : SnocList Char -> Nat- Visibility: export
any : Lexer- Visibility: export
non : Lexer -> Lexer Recognise any character if the sub-lexer `l` fails.
/(?!`l`)./
Visibility: exportis : Char -> Lexer Recognise a specific item.
/[`x`]/
Visibility: exportisNot : Char -> Lexer Recognise anything but the given item.
/[\^`x`]/
Visibility: exportspace : Lexer Recognise a single whitespace character.
Visibility: exportdigit : Lexer Recognise a single digit.
Visibility: exportlike : Char -> Lexer Recognise a specific character (case-insensitive).
/[`x`]/i
Visibility: exportnotLike : Char -> Lexer Recognise anything but the given character (case-insensitive).
/[\^`x`]/i
Visibility: exportoneOf : List Char -> Lexer Recognises one of the given characters.
Visibility: exportrange : Char -> Char -> Lexer Recognise a character in a range. Also works in reverse!
/[`start`-`end`]/
Visibility: exportprefixBy : List (Char -> Bool) -> Lexer- Visibility: export
exact : String -> Lexer- Visibility: export
approx : String -> Lexer- Visibility: export
digits : Lexer Recognise a non-empty sequence of digits.
Visibility: exportsymbol : Lexer Recognise a single non-whitespace, non-alphanumeric character
/[\^\\sA-Za-z0-9]/
Visibility: exportsymbols : Lexer Recognise one or more non-whitespace, non-alphanumeric characters
/[\^\\sA-Za-z0-9]+/
Visibility: exportcontrol : Lexer- Visibility: export
controls : Lexer Recognise one or more control characters
/[\\x00-\\x1f\\x7f-\\x9f]+/
Visibility: exportsomeOf : List Char -> Lexer Recognises a non-empty sequence of the given items
Visibility: exportranges : Char -> Char -> Lexer Recognise some items in a range. Also works in reverse!
/[`start`-`end`]/
Visibility: exportspaces : Lexer Recognise a non-empty sequence of whitespace characters.
Visibility: exportspaceChars : Lexer Recognise a non-empty sequence of space characters.
Visibility: exportnewline : Lexer Recognise a single newline character sequence
Visibility: exportmanyTillNewline : Recognise False Reads characters until the next newline character is
encountered.
Visibility: exportmanyTillLineFeed : Recognise False Reads characters until the next linefeed character (`'\n'`) is
encountered.
Visibility: export Lexer for single line comments starting with the given prefix.
This reads until (but does not include) the first newline
character `'\n'` or `'\r'`.
Visibility: export Lexer for single line comments starting with the given prefix.
This reads until (but does not include) the first line feed
character (`'\n'`).
Visibility: exportatLeast : (n : Nat) -> Lexer -> Recognise (isSucc n)- Visibility: export
exactly : (n : Nat) -> Lexer -> {auto 0 _ : IsSucc n} -> Lexer- Visibility: export
manyUntil : Recognise c -> Lexer -> Recognise False- Visibility: export
someUntil : Recognise c -> Lexer -> Lexer- Visibility: export
manyThen : Recognise c -> Lexer -> Recognise c- Visibility: export
surround : Lexer -> Lexer -> Lexer -> Lexer Recognise zero or more occurrences of a sub-lexer between
delimiting lexers
/`start`(`l`)\*?`end`/
Visibility: exportquote : Lexer -> Lexer -> Lexer Recognise zero or more occurrences of a sub-lexer surrounded
by the same quote lexer on both sides (useful for strings)
/`q`(`l`)\*?`q`/
Visibility: exportescape : Lexer -> Lexer -> Lexer Recognise an escape sub-lexer (often '\\') followed by
another sub-lexer
/[`esc`]`l`/
Visibility: exportstringLit : Lexer- Visibility: export
intLit : Lexer Recognise an integer literal (possibly with a '-' prefix)
/-?[0-9]+/
Visibility: exportintLitPlus : Lexer Recognise an integer literal (possibly with a '+' or '-' prefix)
Visibility: exportbinDigits : Lexer- Visibility: export
hexDigits : Lexer- Visibility: export
octDigits : Lexer- Visibility: export
binLit : Lexer Recognise a binary literal, prefixed by "0b"
/0b[0-1]+/
Visibility: exporthexLit : Lexer Recognise a hexidecimal literal, prefixed by "0x" or "0X"
/0[Xx][0-9A-Fa-f]+/
Visibility: exportoctLit : Lexer Recognise an octal literal, prefixed by "0o"
/0o[0-9A-Fa-f]+/
Visibility: exportdigitsUnderscoredLit : Lexer Recognise a decimal integer literal with optional undescores for
improved readability.
Visibility: exportbinUnderscoredLit : Lexer Recognise a binary literal with optional undescores for
improved readability.
Visibility: exporthexUnderscoredLit : Lexer Recognise a hexadecimal literal with optional undescores for
improved readability.
Visibility: exportoctUnderscoredLit : Lexer Recognise an octal literal with optional undescores for
improved readability.
Visibility: exportcharLit : Lexer Recognise a character literal, including escaped characters.
(Note: doesn't yet handle escape sequences such as \123)
/'(\\\\.|[\^'])'/
Visibility: exportdoubleLit : Lexer- Visibility: export