File tree 3 files changed +4
-9
lines changed
3 files changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -7,11 +7,9 @@ use utils::span_lint;
7
7
8
8
/// **What it does:** Checks for floating point literals that approximate
9
9
/// constants which are defined in
10
- /// [`std::f32::consts`](https://doc.rust-lang.
11
- /// org/stable/std/f32/consts/#constants)
10
+ /// [`std::f32::consts`](https://doc.rust-lang.org/stable/std/f32/consts/#constants)
12
11
/// or
13
- /// [`std::f64::consts`](https://doc.rust-lang.
14
- /// org/stable/std/f64/consts/#constants),
12
+ /// [`std::f64::consts`](https://doc.rust-lang.org/stable/std/f64/consts/#constants),
15
13
/// respectively, suggesting to use the predefined constant.
16
14
///
17
15
/// **Why is this bad?** Usually, the definition in the standard library is more
Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ use utils::span_note_and_lint;
18
18
/// **Example:**
19
19
/// * `let x = {"foo" ;}` when the user almost certainly intended `let x
20
20
/// ={"foo"}`
21
-
22
21
declare_lint ! {
23
22
pub UNIT_EXPR ,
24
23
Warn ,
Original file line number Diff line number Diff line change @@ -29,10 +29,8 @@ declare_lint! {
29
29
"invalid regular expressions"
30
30
}
31
31
32
- /// **What it does:** Checks for trivial [regex] creation (with `Regex::new`,
33
- /// `RegexBuilder::new` or `RegexSet::new`).
34
- ///
35
- /// [regex]: https://crates.io/crates/regex
32
+ /// **What it does:** Checks for trivial [regex](https://crates.io/crates/regex)
33
+ /// creation (with `Regex::new`, `RegexBuilder::new` or `RegexSet::new`).
36
34
///
37
35
/// **Why is this bad?** Matching the regex can likely be replaced by `==` or
38
36
/// `str::starts_with`, `str::ends_with` or `std::contains` or other `str`
You can’t perform that action at this time.
0 commit comments