Skip to content
Snippets Groups Projects
Commit 30f8e786 authored by Yuya Nishihara's avatar Yuya Nishihara
Browse files

rust-filepatterns: use literal b'#' instead of cast

parent 02476018
No related branches found
No related tags found
No related merge requests found
......@@ -243,7 +243,7 @@
for (line_number, mut line) in lines.split(|c| *c == b'\n').enumerate() {
let line_number = line_number + 1;
if line.contains(&('#' as u8)) {
if line.contains(&b'#') {
if let Some(cap) = comment_regex.captures(line) {
line = &line[..cap.get(1).unwrap().end()]
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment