Function summary | |
---|---|
greedy-quant | lexer |
group | lexer |
parse-string | string |
quant | lexer |
reg-expr | lexer |
reverse-strings | parse-tree |
seq | lexer |
Parses and consumes a <group>. The productions are: <group> -> "("<regex>")" "(?:"<regex>")" "(?>"<regex>")" "(?<flags>:"<regex>")" "(?="<regex>")" "(?!"<regex>")" "(?<="<regex>")" "(?<!"<regex>")" "(?("<num>")"<regex>")" "(?("<regex>")"<regex>")" "(?<name>"<regex>")" (when *ALLOW-NAMED-REGISTERS* is T) <legal-token> where <flags> is parsed by the lexer function MAYBE-PARSE-FLAGS. Will return <parse-tree> or (<grouping-type> <parse-tree>) where <grouping-type> is one of six keywords - see source for details.
Parses and consumes a <greedy-quant>. The productions are: <greedy-quant> -> <group> | <group><quantifier> where <quantifier> is parsed by the lexer function GET-QUANTIFIER. Will return <parse-tree> or (:GREEDY-REPETITION <min> <max> <parse-tree>).
Parses and consumes a <quant>. The productions are: <quant> -> <greedy-quant> | <greedy-quant>"?". Will return the <parse-tree> returned by GREEDY-QUANT and optionally change :GREEDY-REPETITION to :NON-GREEDY-REPETITION.
Parses and consumes a <seq>. The productions are: <seq> -> <quant> | <quant><seq>. Will return <parse-tree> or (:SEQUENCE <parse-tree> <parse-tree>).
Parses and consumes a <regex>, a complete regular expression. The productions are: <regex> -> <seq> | <seq>"|"<regex>. Will return <parse-tree> or (:ALTERNATION <parse-tree> <parse-tree>).