diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2022-10-27 20:23:51 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2022-10-27 20:23:51 -0400 |
| commit | 3296ce42d9c97d24ee753c3ce911db75cfe01296 (patch) | |
| tree | 581141ab5765dfa36006b59d99a1ea5bd7e748ad | |
| parent | 69740ed659fd8aae986bc2f269ee100a579b5efd (diff) | |
Fix for numbered capture logic
| -rw-r--r-- | match.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -923,7 +923,7 @@ static match_t *_get_numbered_capture(match_t *m, int *n) match_t *get_numbered_capture(match_t *m, int n) { if (n <= 0) return m; - if (m->pat->type == BP_TAGGED) { + if (m->pat->type == BP_TAGGED || m->pat->type == BP_CAPTURE) { if (m->children) { for (int i = 0; m->children[i]; i++) { match_t *cap = _get_numbered_capture(m->children[i], &n); |
