Skip to content

Commit 264a417

Browse files
authored
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 4cda338 commit 264a417

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

tracing-error/src/subscriber.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,9 +111,9 @@ where
111111
}
112112

113113
impl WithContext {
114-
pub(crate) fn with_context<'a>(
114+
pub(crate) fn with_context(
115115
&self,
116-
dispatch: &'a Dispatch,
116+
dispatch: &Dispatch,
117117
id: &span::Id,
118118
mut f: impl FnMut(&'static Metadata<'static>, &str) -> bool,
119119
) {

tracing-opentelemetry/src/subscriber.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)