]> git.lizzy.rs Git - rust.git/blobdiff - clippy_lints/src/else_if_without_else.rs
Auto merge of #4551 - mikerite:fix-ice-reporting, r=llogiq
[rust.git] / clippy_lints / src / else_if_without_else.rs
index 25a1cde6e5ee74d80c599793fd4ba14e4be0280c..6daf204a5f187587644bab1c255baba8de62b262 100644 (file)
@@ -16,6 +16,9 @@
     ///
     /// **Example:**
     /// ```rust
+    /// # fn a() {}
+    /// # fn b() {}
+    /// # let x: i32 = 1;
     /// if x.is_positive() {
     ///     a();
     /// } else if x.is_negative() {
@@ -26,6 +29,9 @@
     /// Could be written:
     ///
     /// ```rust
+    /// # fn a() {}
+    /// # fn b() {}
+    /// # let x: i32 = 1;
     /// if x.is_positive() {
     ///     a();
     /// } else if x.is_negative() {