diff --git a/clippy_lints/src/doc.rs b/clippy_lints/src/doc.rs index 5f6c15e222d2..10043df9cbf9 100644 --- a/clippy_lints/src/doc.rs +++ b/clippy_lints/src/doc.rs @@ -21,7 +21,7 @@ use url::Url; /// **Examples:** /// ```rust /// /// Do something with the foo_bar parameter. See also -/// that::other::module::foo. +/// /// that::other::module::foo. /// // ^ `foo_bar` and `that::other::module::foo` should be ticked. /// fn doit(foo_bar) { .. } /// ``` diff --git a/clippy_lints/src/drop_forget_ref.rs b/clippy_lints/src/drop_forget_ref.rs index 7acc7805f82a..007accc7fbf8 100644 --- a/clippy_lints/src/drop_forget_ref.rs +++ b/clippy_lints/src/drop_forget_ref.rs @@ -17,7 +17,7 @@ use utils::{is_copy, match_def_path, opt_def_id, paths, span_note_and_lint}; /// ```rust /// let mut lock_guard = mutex.lock(); /// std::mem::drop(&lock_guard) // Should have been drop(lock_guard), mutex -/// still locked +/// // still locked /// operation_that_requires_mutex_to_be_unlocked(); /// ``` declare_clippy_lint! { @@ -60,7 +60,7 @@ declare_clippy_lint! { /// ```rust /// let x:i32 = 42; // i32 implements Copy /// std::mem::drop(x) // A copy of x is passed to the function, leaving the -/// original unaffected +/// // original unaffected /// ``` declare_clippy_lint! { pub DROP_COPY, @@ -87,7 +87,7 @@ declare_clippy_lint! { /// ```rust /// let x:i32 = 42; // i32 implements Copy /// std::mem::forget(x) // A copy of x is passed to the function, leaving the -/// original unaffected +/// // original unaffected /// ``` declare_clippy_lint! { pub FORGET_COPY, diff --git a/clippy_lints/src/transmute.rs b/clippy_lints/src/transmute.rs index 68321e7bd5e3..63ea96bbceac 100644 --- a/clippy_lints/src/transmute.rs +++ b/clippy_lints/src/transmute.rs @@ -16,7 +16,7 @@ use utils::{opt_def_id, sugg}; /// /// **Example:** /// ```rust -/// let ptr: *const T = core::intrinsics::transmute('x')` +/// let ptr: *const T = core::intrinsics::transmute('x') /// ``` declare_clippy_lint! { pub WRONG_TRANSMUTE, @@ -51,8 +51,8 @@ declare_clippy_lint! { /// /// **Example:** /// ```rust -/// core::intrinsics::transmute(t)` // where the result type is the same as -/// `*t` or `&t`'s +/// core::intrinsics::transmute(t) // where the result type is the same as +/// // `*t` or `&t`'s /// ``` declare_clippy_lint! { pub CROSSPOINTER_TRANSMUTE,