Skip to content

Commit

Permalink
Add additional information to references of my_crate in env_filter do…
Browse files Browse the repository at this point in the history
…cs. (#1088)

Co-authored-by: Bryan Garza <1396101+bryangarza@users.noreply.github.com>
  • Loading branch information
2 people authored and hawkw committed Jun 6, 2022
1 parent 6878d8d commit f22f286
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tracing-subscriber/src/filter/env/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,11 @@ impl EnvFilter {
/// # Ok(())
/// # }
/// ```
/// In the above example, substitute `my_crate`, `module`, etc. with the
/// name your target crate/module is imported with. This might be
/// different from the package name in Cargo.toml (`-` is replaced by `_`).
/// Example, if the package name in your Cargo.toml is `MY-FANCY-LIB`, then
/// the corresponding Rust identifier would be `MY_FANCY_LIB`:
pub fn add_directive(mut self, mut directive: Directive) -> Self {
if !self.regex {
directive.deregexify();
Expand Down

0 comments on commit f22f286

Please sign in to comment.