about summary refs log tree commit diff
path: root/clippy_lints/src/unnested_or_patterns.rs
diff options
context:
space:
mode:
authorPhilipp Krones <hello@philkrones.com>2021-07-28 15:06:27 +0200
committerGitHub <noreply@github.com>2021-07-28 15:06:27 +0200
commit464c85c8c1c71feda6e53eb9d8713bfdafaf7d8b (patch)
treee58ac96a0819f774260a28ea7c1dcdcca567bee2 /clippy_lints/src/unnested_or_patterns.rs
parentbcdf147aafc6d1c365487abd88cb0bc1cf5f2e63 (diff)
parent9bc5803195f75895614feae27607564da01d100a (diff)
downloadrust-464c85c8c1c71feda6e53eb9d8713bfdafaf7d8b.tar.gz
rust-464c85c8c1c71feda6e53eb9d8713bfdafaf7d8b.zip
Rollup merge of #7420 - xFrednet:7172-update-lint-documentation, r=flip1995
Update lint documentation to use markdown headlines

This PR updates all lint documentation to use markdown headlines. It additionally removed the *Known problems* section for lints without any problems. I've double-checked all automatic replacements, but a second pair of eyes is definitely appreciated!

I wasn't sure when you wanted to switch to the new metadata collection tomorrow, I therefore prepared this PR today. And that's it this is a standalone PR to keep the other related PRs reviewable.

changelog:  none

r? `@flip1995`

cc: #7172

Note: This should be merged with the other metadata collection related PRs.
Diffstat (limited to 'clippy_lints/src/unnested_or_patterns.rs')
-rw-r--r--clippy_lints/src/unnested_or_patterns.rs11
1 files changed, 3 insertions, 8 deletions
diff --git a/clippy_lints/src/unnested_or_patterns.rs b/clippy_lints/src/unnested_or_patterns.rs
index 07a4e294049..9acfbc994b3 100644
--- a/clippy_lints/src/unnested_or_patterns.rs
+++ b/clippy_lints/src/unnested_or_patterns.rs
@@ -17,22 +17,17 @@ use std::cell::Cell;
 use std::mem;
 
 declare_clippy_lint! {
-    /// **What it does:**
-    ///
+    /// ### What it does
     /// Checks for unnested or-patterns, e.g., `Some(0) | Some(2)` and
     /// suggests replacing the pattern with a nested one, `Some(0 | 2)`.
     ///
     /// Another way to think of this is that it rewrites patterns in
     /// *disjunctive normal form (DNF)* into *conjunctive normal form (CNF)*.
     ///
-    /// **Why is this bad?**
-    ///
+    /// ### Why is this bad?
     /// In the example above, `Some` is repeated, which unncessarily complicates the pattern.
     ///
-    /// **Known problems:** None.
-    ///
-    /// **Example:**
-    ///
+    /// ### Example
     /// ```rust
     /// fn main() {
     ///     if let Some(0) | Some(2) = Some(0) {}