1
0
mirror of https://github.com/BurntSushi/ripgrep.git synced 2025-03-17 20:28:03 +02:00
Andrew Gallant be9e308999 globset: use a Pool from regex-automata
In the time before, we just used a RegexSet from the regex crate. That
allocated unconditionally, so there was nothing we could do and it
didn't expose any APIs to reuse that memory. But now that we're using
the lower level regex-automata, we can reuse a PatternSet.

Ideally we would just provide a way for the caller to build a PatternSet
(perhaps via an opaque type) so that we don't have to shuffle data into
a PatternSet and then back into the caller's `Vec<usize>`. But this at
least avoids allocating for every search.
2023-10-09 20:29:52 -04:00
..
2023-10-09 20:29:52 -04:00
2023-10-09 20:29:52 -04:00
2023-10-09 20:29:52 -04:00
2023-10-09 20:29:52 -04:00
2023-10-09 20:29:52 -04:00
2023-10-09 20:29:52 -04:00
2023-10-09 20:29:52 -04:00
2023-10-09 20:29:52 -04:00