fn on_enter(&self, span: &Id, ctx: Context<'_, S>) {
        let span = ctx.span(span).expect("Span not found, this is a bug");

        let mut extensions = span.extensions_mut();
        if extensions.get_mut::<Instant>().is_none() {
            extensions.insert(Instant::now());
        }
    }
/// When we enter a span **for the first time** save the timestamp in its extensions.
When we enter a span **for the first time** save the timestamp in its extensions.
When we enter a span ** for the first time ** save the timestamp in its extensions .
fn on_enter(&self, span: &Id, ctx: Context<'_, S>) {
        let span = ctx.span(span).expect("Span not found, this is a bug");
        let mut extensions = span.extensions_mut();
        if extensions.get_mut::<Instant>().is_none() {
            extensions.insert(Instant::now());
        }
    }
fn on_enter ( & self , span : & Id , ctx : Context < ' _ , S > ) { let span = ctx . span ( span ) . expect ( " " ) ; let mut extensions = span . extensions_mut ( ) ; if extensions . get_mut :: < Instant > ( ) . is_none ( ) { extensions . insert ( Instant :: now ( ) ) ; } }
When we enter a span **for the first time** save the timestamp in its extensions.
When we enter a span ** for the first time ** save the timestamp in its extensions .
&self
span
&Id
ctx
Context<'_, S>
&self
span
&Id
ctx
Context<'_, S>