]> git.lizzy.rs Git - rust.git/blobdiff - clippy_lints/src/derivable_impls.rs
Auto merge of #9148 - arieluy:then_some_unwrap_or, r=Jarcho
[rust.git] / clippy_lints / src / derivable_impls.rs
index 34a5f8444dea0af0d58a1d221db4a1ca3998999a..4d7f4076d7b5134b85e08e04b254e420971f964f 100644 (file)
@@ -21,7 +21,7 @@
     ///     bar: bool
     /// }
     ///
-    /// impl std::default::Default for Foo {
+    /// impl Default for Foo {
     ///     fn default() -> Self {
     ///         Self {
     ///             bar: false
@@ -30,8 +30,7 @@
     /// }
     /// ```
     ///
-    /// Could be written as:
-    ///
+    /// Use instead:
     /// ```rust
     /// #[derive(Default)]
     /// struct Foo {
@@ -45,7 +44,6 @@
     /// specialized than what derive will produce. This lint can't detect the manual `impl`
     /// has exactly equal bounds, and therefore this lint is disabled for types with
     /// generic parameters.
-    ///
     #[clippy::version = "1.57.0"]
     pub DERIVABLE_IMPLS,
     complexity,