mirror of
https://github.com/allankoechke/rust.git
synced 2026-12-04 17:22:19 +00:00
String::remove_matches O(n^2) -> O(n) Copy only non-matching bytes. Replace collection of matches into a vector with iteration over rejections, exploiting the guarantee that we mutate parts of the haystack that have already been searched over. r? `@joshtriplett`