Skip to content

Commit

Permalink
dbg_macro: notes about VCS and log::debug!(..)
Browse files Browse the repository at this point in the history
  • Loading branch information
Centril committed Sep 20, 2018
1 parent a9d2f38 commit 1d2a1bf
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/libstd/macros.rs
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,10 @@ macro_rules! eprintln {
/// to give up ownership, you can instead borrow with `dbg!(&expr)`
/// for some expression `expr`.
///
/// and should be avoided
/// for longer periods in version control
/// Note that the macro is intended as a debugging tool and therefore you
/// should avoid having uses of it in version control for longer periods.
/// Use cases involving debug output that should be added to version control
/// may be better served by macros such as `debug!` from the `log` crate.
///
/// # Stability
///
Expand All @@ -261,7 +263,7 @@ macro_rules! eprintln {
///
/// ```rust
/// #![feature(dbg_macro)]
///
///
/// fn foo(n: usize) {
/// if let Some(_) = dbg!(n.checked_sub(4)) {
/// // ...
Expand Down
Empty file modified src/test/ui/rfc-2361-dbg-macro/dbg-macro-expected-behavior.rs
100755 → 100644
Empty file.
Empty file modified src/test/ui/rfc-2361-dbg-macro/dbg-macro-feature-gate.rs
100755 → 100644
Empty file.
Empty file modified src/test/ui/rfc-2361-dbg-macro/dbg-macro-move-semantics.rs
100755 → 100644
Empty file.
Empty file modified src/test/ui/rfc-2361-dbg-macro/dbg-macro-requires-debug.rs
100755 → 100644
Empty file.

0 comments on commit 1d2a1bf

Please sign in to comment.