Skip to content

Commit

Permalink
uh oh
Browse files Browse the repository at this point in the history
  • Loading branch information
davidbarsky committed Jul 22, 2020
1 parent ea5c7b5 commit 2c4f3d1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/examples/echo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ async fn main() -> Result<(), Box<dyn Error + Send + Sync + 'static>> {
info!(message = "echo'd data", %peer_addr, size = n);
}
})
.instrument(info_span!("echo", %peer_addr));
.instrument(info_span!("echo", %peer_addr))
.await?;
}
}
2 changes: 2 additions & 0 deletions tracing/src/instrument.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,7 @@ pub trait WithSubscriber: Sized {
pin_project! {
/// A future that has been instrumented with a `tracing` subscriber.
#[derive(Clone, Debug)]
#[must_use = "futures do nothing unless you `.await` or poll them"]
pub struct WithDispatch<T> {
#[pin]
inner: T,
Expand All @@ -133,6 +134,7 @@ pin_project! {
pin_project! {
/// A future that has been instrumented with a `tracing` span.
#[derive(Debug, Clone)]
#[must_use = "futures do nothing unless you `.await` or poll them"]
pub struct Instrumented<T> {
#[pin]
inner: T,
Expand Down

0 comments on commit 2c4f3d1

Please sign in to comment.