replace odd line terminator #1328
Answered
by
BurntSushi
Maikel1963
asked this question in
Q&A
-
|
Hello, the regex I want to use goes like: |
Beta Was this translation helpful? Give feedback.
Answered by
BurntSushi
Jan 26, 2026
Replies: 1 comment 5 replies
-
|
Please provide an MRE. |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

If you need help sharing a small Rust program with a short CSV string embedded inside of it, then I'd suggest seeking help in the Rust Community Discord.
The reason why I am insisting on this is because I cannot diagnose your problem from the information given. The regex
r"(?m)\r\r"is valid and will find occurrences of\r\r: https://play.rust-lang.org/?version=stable&mode=debug&edition=2024&gist=0acb638cc7baecb7a0ab054428b58185So I'm forced to conclude that your problem is elsewhere. Hence the request for an MRE. :-)
(Note that
(?m)in your regex is strictly superfluous. Themflag only impacts the behavior of^and$, and neither^nor$appear anywhere in your regex.)