Skip to content

Commit

Permalink
clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
robjtede committed Jul 16, 2021
1 parent ad22a93 commit a0fe2a9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion actix-router/src/url.rs
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ mod tests {
}

fn percent_encode(data: &[u8]) -> String {
data.into_iter().map(|c| format!("%{:02X}", c)).collect()
data.iter().map(|c| format!("%{:02X}", c)).collect()
}

#[test]
Expand Down
2 changes: 1 addition & 1 deletion actix-rt/tests/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ fn new_arbiter_with_tokio() {

arb.join().unwrap();

assert_eq!(false, counter.load(Ordering::SeqCst));
assert!(!counter.load(Ordering::SeqCst));
}

#[test]
Expand Down
5 changes: 3 additions & 2 deletions actix-server/src/worker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ fn handle_pair(
/// On reaching counter limit worker would use `mio::Waker` and `WakerQueue` to wake up `Accept`
/// and notify it to update cached `Availability` again to mark worker as able to accept work again.
///
/// Hense a wake up would only happen after `Accept` increment it to limit.
/// Hence, a wake up would only happen after `Accept` increment it to limit.
/// And a decrement to limit always wake up `Accept`.
#[derive(Clone)]
pub(crate) struct Counter {
Expand Down Expand Up @@ -179,8 +179,9 @@ impl WorkerHandleAccept {
/// Handle to worker than can send stop message to worker.
///
/// Held by [ServerBuilder](crate::builder::ServerBuilder).
#[derive(Debug)]
pub(crate) struct WorkerHandleServer {
pub idx: usize,
idx: usize,
tx: UnboundedSender<Stop>,
}

Expand Down

0 comments on commit a0fe2a9

Please sign in to comment.