]> git.lizzy.rs Git - rust.git/blobdiff - src/tools/clippy/clippy_lints/src/dbg_macro.rs
Merge commit '7f27e2e74ef957baa382dc05cf08df6368165c74' into clippyup
[rust.git] / src / tools / clippy / clippy_lints / src / dbg_macro.rs
index fe9f4f9ae3cb9f08ebeef9e3d586fb45650dc3ab..799e71e847a9fcf60fc176d86e413f5aa7de57a1 100644 (file)
 
 declare_clippy_lint! {
     /// ### What it does
-    /// Checks for usage of dbg!() macro.
+    /// Checks for usage of the [`dbg!`](https://doc.rust-lang.org/std/macro.dbg.html) macro.
     ///
     /// ### Why is this bad?
-    /// `dbg!` macro is intended as a debugging tool. It
-    /// should not be in version control.
+    /// The `dbg!` macro is intended as a debugging tool. It should not be present in released
+    /// software or committed to a version control system.
     ///
     /// ### Example
     /// ```rust,ignore
@@ -91,8 +91,8 @@ fn check_expr(&mut self, cx: &LateContext<'_>, expr: &Expr<'_>) {
                 cx,
                 DBG_MACRO,
                 macro_call.span,
-                "`dbg!` macro is intended as a debugging tool",
-                "ensure to avoid having uses of it in version control",
+                "the `dbg!` macro is intended as a debugging tool",
+                "remove the invocation before committing it to a version control system",
                 suggestion,
                 applicability,
             );