Skip to content

Commit 33b487e

Browse files
committed
chore: address clippy lints
1 parent 182055b commit 33b487e

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

actix-router/src/quoter.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ fn hex_pair_to_char(d1: u8, d2: u8) -> Option<u8> {
105105
let d_low = char::from(d2).to_digit(16)?;
106106

107107
// left shift high nibble by 4 bits
108-
Some((d_high as u8) << 4 | (d_low as u8))
108+
Some(((d_high as u8) << 4) | (d_low as u8))
109109
}
110110

111111
#[derive(Debug, Default, Clone)]

actix-router/src/resource.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1021,6 +1021,7 @@ impl ResourceDef {
10211021
panic!("prefix resource definitions should not have tail segments");
10221022
}
10231023

1024+
#[allow(clippy::literal_string_with_formatting_args)]
10241025
if unprocessed.ends_with('*') {
10251026
// unnamed tail segment
10261027

@@ -1369,6 +1370,7 @@ mod tests {
13691370
assert_eq!(path.unprocessed(), "");
13701371
}
13711372

1373+
#[expect(clippy::literal_string_with_formatting_args)]
13721374
#[test]
13731375
fn newline_patterns_and_paths() {
13741376
let re = ResourceDef::new("/user/a\nb");

actix-router/src/router.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ mod tests {
145145
};
146146

147147
#[allow(clippy::cognitive_complexity)]
148+
#[expect(clippy::literal_string_with_formatting_args)]
148149
#[test]
149150
fn test_recognizer_1() {
150151
let mut router = Router::<usize>::build();

0 commit comments

Comments
 (0)