aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2022-05-12 12:11:28 -0400
committerBruce Hill <bruce@bruce-hill.com>2022-05-12 12:11:28 -0400
commit56da250d69615d70774dbc361fa2693cca1e3df4 (patch)
treedbdeb2be018c5f10c13f721965b3bebff2283e88 /README.md
parente484a888151460ffc25a8478d9a9c9836652a35c (diff)
Split backref/named captures into separate concepts for performance
reasons.
Diffstat (limited to 'README.md')
-rw-r--r--README.md5
1 files changed, 3 insertions, 2 deletions
diff --git a/README.md b/README.md
index 5e7d716..7e7d714 100644
--- a/README.md
+++ b/README.md
@@ -74,8 +74,9 @@ Pattern | Meaning
`+pat` | 1 or more occurrences of `pat` (shorthand for `1+pat`)
`<pat` | `pat` matches just before the current position (lookbehind)
`>pat` | `pat` matches just in front of the current position (lookahead)
-`@pat` | Capture `pat` (used for text replacement and backreferences)
-`@foo=pat` | Let `foo` be the text of `pat` (used for text replacement and backreferences)
+`@pat` | Capture `pat` (used for text replacement)
+`@foo=pat` | Capture `pat` with the name `foo` attached (used for text replacement)
+`@foo:pat` | Let `foo` be the text of `pat` (used for backreferences)
`pat => "replacement"` | Match `pat` and replace it with `replacement`
`(pat1 @keep=pat2) => "@keep"` | Match `pat1` followed by `pat2` and replace it with the text of `pat2`
`pat1~pat2` | `pat1` when `pat2` can be found within the result