Files
ripgrep/crates
Ben Heidemann d969ebc1e5 globset: make GlobSet::new public
For users of globset who already have a `Vec<Glob>` (or similar),
the current API requires them to iterate over their `Vec<Glob>`,
calling `GlobSetBuilder::add` for each `Glob`, thus constructing a new
`Vec<Glob>` internal to the GlobSetBuilder. This makes the consuming
code unnecessarily verbose. (There is unlikely to be any meaningful
performance impact of this, however, since the cost of allocating a new
`Vec` is likely marginal compared to the cost of glob compilation.)

Instead of taking a `&[Glob]`, we accept an iterator of anything that
can be borrowed as a `&Glob`. This required some light refactoring of
the constructor, but nothing onerous.

Closes #3066
2025-08-19 20:15:25 -04:00
..
2024-09-08 22:06:59 -04:00
2025-08-19 20:15:25 -04:00
2024-09-08 22:11:00 -04:00
2025-08-17 10:32:59 -04:00
2024-09-08 22:07:52 -04:00