Skip to content

Commit 1c65bda

Browse files
author
Ype Kingma
committed
cargo dev update_lints and fmt, move use stmts to start of source file
1 parent a3b4021 commit 1c65bda

File tree

6 files changed

+23
-23
lines changed

6 files changed

+23
-23
lines changed

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5453,7 +5453,7 @@ Released 2018-09-13
54535453
[`explicit_deref_methods`]: https://rust-lang.github.io/rust-clippy/master/index.html#explicit_deref_methods
54545454
[`explicit_into_iter_loop`]: https://rust-lang.github.io/rust-clippy/master/index.html#explicit_into_iter_loop
54555455
[`explicit_iter_loop`]: https://rust-lang.github.io/rust-clippy/master/index.html#explicit_iter_loop
5456-
[`explicit_lifetimes_bound_nested_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#explicit_lifetimes_bound_nested_ref
5456+
[`explicit_lifetimes_bound`]: https://rust-lang.github.io/rust-clippy/master/index.html#explicit_lifetimes_bound
54575457
[`explicit_write`]: https://rust-lang.github.io/rust-clippy/master/index.html#explicit_write
54585458
[`extend_from_slice`]: https://rust-lang.github.io/rust-clippy/master/index.html#extend_from_slice
54595459
[`extend_with_drain`]: https://rust-lang.github.io/rust-clippy/master/index.html#extend_with_drain
@@ -5515,7 +5515,7 @@ Released 2018-09-13
55155515
[`impl_trait_in_params`]: https://rust-lang.github.io/rust-clippy/master/index.html#impl_trait_in_params
55165516
[`implicit_clone`]: https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone
55175517
[`implicit_hasher`]: https://rust-lang.github.io/rust-clippy/master/index.html#implicit_hasher
5518-
[`implicit_lifetimes_bound_nested_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#implicit_lifetimes_bound_nested_ref
5518+
[`implicit_lifetimes_bound`]: https://rust-lang.github.io/rust-clippy/master/index.html#implicit_lifetimes_bound
55195519
[`implicit_return`]: https://rust-lang.github.io/rust-clippy/master/index.html#implicit_return
55205520
[`implicit_saturating_add`]: https://rust-lang.github.io/rust-clippy/master/index.html#implicit_saturating_add
55215521
[`implicit_saturating_sub`]: https://rust-lang.github.io/rust-clippy/master/index.html#implicit_saturating_sub

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
A collection of lints to catch common mistakes and improve your [Rust](https://github.com/rust-lang/rust) code.
77

8-
[There are over 700 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)
8+
[There are over 750 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)
99

1010
Lints are divided into categories, each with a default [lint level](https://doc.rust-lang.org/rustc/lints/levels.html).
1111
You can choose how much Clippy is supposed to ~~annoy~~ help you by changing the lint level by category.

book/src/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
A collection of lints to catch common mistakes and improve your
77
[Rust](https://github.com/rust-lang/rust) code.
88

9-
[There are over 700 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)
9+
[There are over 750 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)
1010

1111
Lints are divided into categories, each with a default [lint
1212
level](https://doc.rust-lang.org/rustc/lints/levels.html). You can choose how

clippy_lints/src/declared_lints.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,8 +266,8 @@ pub static LINTS: &[&crate::LintInfo] = &[
266266
crate::let_with_type_underscore::LET_WITH_TYPE_UNDERSCORE_INFO,
267267
crate::lifetimes::EXTRA_UNUSED_LIFETIMES_INFO,
268268
crate::lifetimes::NEEDLESS_LIFETIMES_INFO,
269-
crate::lifetimes_bound_nested_ref::IMPLICIT_LIFETIMES_BOUND_INFO,
270269
crate::lifetimes_bound_nested_ref::EXPLICIT_LIFETIMES_BOUND_INFO,
270+
crate::lifetimes_bound_nested_ref::IMPLICIT_LIFETIMES_BOUND_INFO,
271271
crate::lines_filter_map_ok::LINES_FILTER_MAP_OK_INFO,
272272
crate::literal_representation::DECIMAL_LITERAL_REPRESENTATION_INFO,
273273
crate::literal_representation::INCONSISTENT_DIGIT_GROUPING_INFO,

clippy_lints/src/lifetimes_bound_nested_ref.rs

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
use clippy_utils::diagnostics::{span_lint_and_note, span_lint_and_then};
2+
use rustc_ast::visit::FnKind;
3+
use rustc_ast::{
4+
AngleBracketedArg, FnRetTy, GenericArg, GenericArgs, GenericBound, GenericParamKind, Generics, Item, ItemKind,
5+
NodeId, Path, Ty, TyKind, WherePredicate,
6+
};
7+
use rustc_errors::Applicability;
8+
use rustc_lint::{EarlyContext, EarlyLintPass, Lint, LintContext};
9+
use rustc_session::impl_lint_pass;
10+
use rustc_span::symbol::Ident;
11+
use rustc_span::{Span, Symbol};
12+
use std::collections::BTreeMap;
13+
use std::collections::btree_map::Entry;
14+
15+
extern crate rustc_hash;
16+
use rustc_hash::FxHashMap;
17+
118
/// Lints to help dealing with unsoundness due to a compiler bug described here:
219
/// <https://github.com/rust-lang/rustc-dev-guide/blob/478a77a902f64e5128e7164e4e8a3980cfe4b133/src/traits/implied-bounds.md>.
320
///
@@ -19,23 +36,6 @@
1936
/// There is also a reverse lint that suggests to remove lifetime bounds
2037
/// that are implied by nested references. This reverse lint is intended to be used only
2138
/// when the compiler has been fixed to handle these lifetime bounds correctly.
22-
use std::collections::btree_map::Entry;
23-
use std::collections::BTreeMap;
24-
25-
use clippy_utils::diagnostics::{span_lint_and_note, span_lint_and_then};
26-
use rustc_ast::visit::FnKind;
27-
use rustc_ast::{
28-
AngleBracketedArg, FnRetTy, GenericArg, GenericArgs, GenericBound, GenericParamKind, Generics, Item, ItemKind,
29-
NodeId, Path, Ty, TyKind, WherePredicate,
30-
};
31-
use rustc_errors::Applicability;
32-
use rustc_lint::{EarlyContext, EarlyLintPass, Lint, LintContext};
33-
use rustc_session::impl_lint_pass;
34-
use rustc_span::symbol::Ident;
35-
use rustc_span::{Span, Symbol};
36-
37-
extern crate rustc_hash;
38-
use rustc_hash::FxHashMap;
3939
4040
declare_clippy_lint! {
4141
/// ### What it does

tests/ui/lifetimes_bound_nested_ref_impl.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// This was started as a copy from the fixed output of lifetimes_bound_nested_ref_expl.fixed
1+
// This was started as a copy from the fixed output of lifetimes_bound_nested_ref_expl.fixed
22
// Adapted: the lint name and the code comments.
33
#![warn(clippy::implicit_lifetimes_bound)]
44
use core::mem::MaybeUninit;

0 commit comments

Comments
 (0)