Skip to content

Commit

Permalink
chore: fix tracing-macros::dbg (#1054)
Browse files Browse the repository at this point in the history
…and the `factorial` example.
  • Loading branch information
dvdplm authored Oct 19, 2020
1 parent cd911e0 commit 19af292
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
5 changes: 2 additions & 3 deletions tracing-macros/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,10 @@ keywords = ["logging", "tracing"]
license = "MIT"

[dependencies]
tracing = "0.1.18"
tracing = "0.1.20"

[dev-dependencies]
tracing-log = "0.1"
env_logger = "0.7"
tracing-subscriber = "0.2"

[badges]
maintenance = { status = "experimental" }
4 changes: 1 addition & 3 deletions tracing-macros/examples/factorial.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ fn factorial(n: u32) -> u32 {
}

fn main() {
env_logger::Builder::new().parse_filters("trace").init();
#[allow(deprecated)]
let subscriber = tracing_log::TraceLogger::new();
let subscriber = tracing_subscriber::fmt().finish();

tracing::subscriber::with_default(subscriber, || dbg!(factorial(4)));
}

0 comments on commit 19af292

Please sign in to comment.