]> git.lizzy.rs Git - rust.git/commitdiff
fix doc
authorChristoph Walcher <christoph-wa@gmx.de>
Tue, 4 Aug 2020 19:07:35 +0000 (21:07 +0200)
committerChristoph Walcher <christoph-wa@gmx.de>
Fri, 7 Aug 2020 16:08:51 +0000 (18:08 +0200)
clippy_lints/src/needless_fn_self_type.rs

index 050a03467fb0174e71f9e8b776dec75a03161e1c..b71f2fbbd46e601da4484f00e01a021e784c3b6d 100644 (file)
     ///
     /// **Example:**
     /// ```rust
+    /// enum ValType {
+    ///     I32,
+    ///     I64,
+    ///     F32,
+    ///     F64,
+    /// }
+    ///
     /// impl ValType {
     ///     pub fn bytes(self: Self) -> usize {
     ///         match self {
     /// Could be rewritten as
     ///
     /// ```rust
+    /// enum ValType {
+    ///     I32,
+    ///     I64,
+    ///     F32,
+    ///     F64,
+    /// }
+    ///
     /// impl ValType {
     ///     pub fn bytes(self) -> usize {
     ///         match self {