-
Notifications
You must be signed in to change notification settings - Fork 459
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Regex on text streams #25
Comments
Looking at the original issue, I did some research (rust-lang/rust#14015) on this a while back and I think I concluded that this was hard/impossible to do in the general case. I would be very happy to hear about a more specific proposal in a new issue. |
(In my case I'm streaming stdout of a child process on a server back to a browser.) Would it be possible to give a closure that acted on the match and returned the replacement rather than trying to return matches in the stream? That way you might be able to still deal with &str rather than having to allocate. I do wonder if we're really asking for a pure rust SED clone. |
@gilescope This issue is extremely old. Please see #425 for updated and very in depth discussion on this task. Closures or not-closures isn't really the issue. |
Thanks for pointing me in the right direction, yes I can see it's non-trivial. |
Wednesday May 07, 2014 at 14:18 GMT
For earlier discussion, see rust-lang/rust#14015
This issue was labelled with: A-libs in the Rust repository
Regex library defines methods for find/replace on strings, but what about text streams?
The text was updated successfully, but these errors were encountered: