Menu

Tree [ef709f] default tip /
 History

Read Only access


File Date Author Commit
 docs 2025-11-28 ggb ggb [6e6202] Added match_empty()
 temp 2025-09-20 ggb ggb [814b53] Start split of string_matchers from string_extras
 .hgignore 2025-08-27 ggb ggb [875dd8] Improved documentation.
 .hgtags 2025-11-28 ggb ggb [ef709f] Added tag v0-15 for changeset 6e62028c7b52
 README.md 2025-11-28 ggb ggb [6e6202] Added match_empty()
 docgen.sh 2025-04-28 ggb ggb [7e5aa0] Added natch_any
 docs.html 2025-04-28 ggb ggb [7e5aa0] Added natch_any
 string_matchers.nim 2025-11-28 ggb ggb [6e6202] Added match_empty()
 string_matchers.nimble 2025-11-28 ggb ggb [6e6202] Added match_empty()

Read Me

Nim functions to match portions of strings

More details can be found in the code comments or the documentation that can be generated from those comments.

Functions

match_any

Compare string to array of options

match_eos

Test if given position is within bounds of a given string.

match_empty

Test if remainder of string is white space

match_to_eos

Test if totality of string matches specified match criteria.

match_true

Skip over input characters that match condition and return offset
to first character that fails to meet specified condition.

match_false

Skip over input characters that do not match condition and return
offset to first character that does match the condition.

match_quotes

Return position beyond closing quote after pair of quotes.

match_brackets

Return position after closing bracket taking into account bracket nesting.

match_word_boundaries

Return offsets to start and end of next word.

match_token_boundaries

Return offsets to start and end of next arbitrary token.

match_indentifier_boundaries

Return offsets to start and end of next valid identifier.

match_until

Return substring that starts at beginning of string and contains characters until condition is met.

match_prefix

Test that short string matches start of long string.

Installation

    nimble install "http://hg.code.sf.net/p/nim-string-matchers/code"
MongoDB Logo MongoDB