From 214a395117ba41cdc31ca690546561dd0bc1df42 Mon Sep 17 00:00:00 2001 From: Guilherme Amorim Date: Tue, 5 Sep 2023 13:26:06 +0200 Subject: [PATCH] Remove no-op regex escapes (#52) This just removes the unnecessary / invalid escapes. Addresses #50 --- src/compose/comment_strip_iter.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/compose/comment_strip_iter.rs b/src/compose/comment_strip_iter.rs index 4e74ea7..4d12a5a 100644 --- a/src/compose/comment_strip_iter.rs +++ b/src/compose/comment_strip_iter.rs @@ -3,7 +3,7 @@ use std::{borrow::Cow, str::Lines}; use regex::Regex; static RE_COMMENT: once_cell::sync::Lazy = - once_cell::sync::Lazy::new(|| Regex::new(r"(\/\/|\/\*|\*\/)").unwrap()); + once_cell::sync::Lazy::new(|| Regex::new(r"(//|/\*|\*/)").unwrap()); pub struct CommentReplaceIter<'a> { lines: &'a mut Lines<'a>,