Skip to content

Commit 2ea8f8c

Browse files
hdshawkw
authored andcommitted
chore: fix new clippy lints from 1.67.0 (#2451)
There are new warnings as errors reported by clippy in Rust 1.67.0. This are causing builds to fail, e.g.: https://github.com/tokio-rs/tracing/actions/runs/4027112923/jobs/6922513360 In both cases they are reports of lifetimes that can be elided. This change removes the unnecessary lifetime annotations to make clippy happy.
1 parent 7cceb79 commit 2ea8f8c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

tracing-error/src/layer.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,9 +103,9 @@ where
103103
}
104104

105105
impl WithContext {
106-
pub(crate) fn with_context<'a>(
106+
pub(crate) fn with_context(
107107
&self,
108-
dispatch: &'a Dispatch,
108+
dispatch: &Dispatch,
109109
id: &span::Id,
110110
mut f: impl FnMut(&'static Metadata<'static>, &str) -> bool,
111111
) {

tracing-opentelemetry/src/layer.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,9 +83,9 @@ pub(crate) struct WithContext(
8383
impl WithContext {
8484
// This function allows a function to be called in the context of the
8585
// "remembered" subscriber.
86-
pub(crate) fn with_context<'a>(
86+
pub(crate) fn with_context(
8787
&self,
88-
dispatch: &'a tracing::Dispatch,
88+
dispatch: &tracing::Dispatch,
8989
id: &span::Id,
9090
mut f: impl FnMut(&mut OtelData, &dyn PreSampledTracer),
9191
) {

0 commit comments

Comments
 (0)