From e53f3a57a0178aa4e8b736eac13c07f8a41fda39 Mon Sep 17 00:00:00 2001 From: Bugen Zhao Date: Tue, 24 Oct 2023 16:05:26 +0800 Subject: [PATCH] fix clippy Signed-off-by: Bugen Zhao --- src/frontend/src/optimizer/plan_node/logical_share.rs | 2 +- src/frontend/src/optimizer/plan_node/mod.rs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/frontend/src/optimizer/plan_node/logical_share.rs b/src/frontend/src/optimizer/plan_node/logical_share.rs index d0cec9108a555..5fe4347a19134 100644 --- a/src/frontend/src/optimizer/plan_node/logical_share.rs +++ b/src/frontend/src/optimizer/plan_node/logical_share.rs @@ -68,7 +68,7 @@ impl LogicalShare { LogicalShare::new(input).into() } - pub(super) fn pretty_fields<'a>(base: impl GenericPlanRef, name: &'a str) -> XmlNode<'a> { + pub(super) fn pretty_fields(base: impl GenericPlanRef, name: &str) -> XmlNode<'_> { childless_record(name, vec![("id", Pretty::debug(&base.id().0))]) } } diff --git a/src/frontend/src/optimizer/plan_node/mod.rs b/src/frontend/src/optimizer/plan_node/mod.rs index beaaa18726dfe..ec7777e42e737 100644 --- a/src/frontend/src/optimizer/plan_node/mod.rs +++ b/src/frontend/src/optimizer/plan_node/mod.rs @@ -183,6 +183,7 @@ impl_downcast!(PlanNode); // Using a new type wrapper allows direct function implementation on `PlanRef`, // and we currently need a manual implementation of `PartialEq` for `PlanRef`. +#[allow(clippy::derived_hash_with_manual_eq)] #[derive(Clone, Debug, Eq, Hash)] pub struct PlanRef(Rc); @@ -528,7 +529,7 @@ impl GenericPlanRef for PlanRef { self.plan_base().schema() } - fn stream_key<'a>(&'a self) -> Option<&'a [usize]> { + fn stream_key(&self) -> Option<&[usize]> { self.plan_base().stream_key() }