refactor: upgrade to Rust 2024

This commit is contained in:
link2xt
2025-06-27 02:01:37 +00:00
committed by l
parent 0ffd4d9f87
commit 5c3de759d3
94 changed files with 1083 additions and 711 deletions

View File

@@ -165,11 +165,12 @@ pub(crate) fn simplify(mut input: String, is_chat_message: bool) -> SimplifiedTe
/// a message is forwarded or not.
fn skip_forward_header<'a>(lines: &'a [&str]) -> (&'a [&'a str], bool) {
match lines {
["---------- Forwarded message ----------", first_line, "", rest @ ..]
if first_line.starts_with("From: ") =>
{
(rest, true)
}
[
"---------- Forwarded message ----------",
first_line,
"",
rest @ ..,
] if first_line.starts_with("From: ") => (rest, true),
_ => (lines, false),
}
}