mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-09-07 00:00:08 +02:00
chore: fix clippy check failure (#1569)
This commit is contained in:
@@ -395,6 +395,7 @@ impl Pool {
|
|||||||
|
|
||||||
/// If there are any other workers currently relaxing, signal them that work
|
/// If there are any other workers currently relaxing, signal them that work
|
||||||
/// is available so that they can try to find more work to process.
|
/// is available so that they can try to find more work to process.
|
||||||
|
#[allow(clippy::cognitive_complexity)] // https://github.com/rust-lang/rust-clippy/issues/3900
|
||||||
pub(crate) fn signal_work(&self, pool: &Arc<Pool>) {
|
pub(crate) fn signal_work(&self, pool: &Arc<Pool>) {
|
||||||
debug_assert_eq!(*self, **pool);
|
debug_assert_eq!(*self, **pool);
|
||||||
|
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ impl Task {
|
|||||||
/// scheduled again.
|
/// scheduled again.
|
||||||
///
|
///
|
||||||
// tracing macro expansion adds enough branches to make clippy angry here.
|
// tracing macro expansion adds enough branches to make clippy angry here.
|
||||||
#[allow(clippy::cognitive_complexity)]
|
#[allow(clippy::cognitive_complexity)] // https://github.com/rust-lang/rust-clippy/issues/3900
|
||||||
pub(crate) fn run(me: &Arc<Task>, pool: &Arc<Pool>) -> Run {
|
pub(crate) fn run(me: &Arc<Task>, pool: &Arc<Pool>) -> Run {
|
||||||
use self::State::*;
|
use self::State::*;
|
||||||
#[cfg(feature = "tracing")]
|
#[cfg(feature = "tracing")]
|
||||||
|
|||||||
@@ -564,7 +564,7 @@ impl Worker {
|
|||||||
///
|
///
|
||||||
/// Returns `true` if woken up due to new work arriving.
|
/// Returns `true` if woken up due to new work arriving.
|
||||||
// tracing macro expansion adds enough branches to make clippy angry here.
|
// tracing macro expansion adds enough branches to make clippy angry here.
|
||||||
#[cfg_attr(feature = "tracing", allow(clippy::cognitive_complexity))]
|
#[allow(clippy::cognitive_complexity)] // https://github.com/rust-lang/rust-clippy/issues/3900
|
||||||
fn sleep(&self) -> bool {
|
fn sleep(&self) -> bool {
|
||||||
use self::Lifecycle::*;
|
use self::Lifecycle::*;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user