Skip to content

Commit c8db189

Browse files
author
Henri Lunnikivi
committed
Run update_lints
1 parent c1bee66 commit c8db189

File tree

4 files changed

+13
-2
lines changed

4 files changed

+13
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1006,6 +1006,7 @@ Released 2018-09-13
10061006
[`extend_from_slice`]: https://rust-lang.github.io/rust-clippy/master/index.html#extend_from_slice
10071007
[`extra_unused_lifetimes`]: https://rust-lang.github.io/rust-clippy/master/index.html#extra_unused_lifetimes
10081008
[`fallible_impl_from`]: https://rust-lang.github.io/rust-clippy/master/index.html#fallible_impl_from
1009+
[`field_reassign_with_default`]: https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
10091010
[`filter_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#filter_map
10101011
[`filter_map_next`]: https://rust-lang.github.io/rust-clippy/master/index.html#filter_map_next
10111012
[`filter_next`]: https://rust-lang.github.io/rust-clippy/master/index.html#filter_next

README.md

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

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

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

1111
We have a bunch of lint categories to allow you to choose how much Clippy is supposed to ~~annoy~~ help you:
1212

clippy_lints/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@ pub mod excessive_precision;
191191
pub mod exit;
192192
pub mod explicit_write;
193193
pub mod fallible_impl_from;
194+
pub mod field_reassign_with_default;
194195
pub mod format;
195196
pub mod formatting;
196197
pub mod functions;
@@ -505,6 +506,7 @@ pub fn register_plugins(store: &mut lint::LintStore, sess: &Session, conf: &Conf
505506
&exit::EXIT,
506507
&explicit_write::EXPLICIT_WRITE,
507508
&fallible_impl_from::FALLIBLE_IMPL_FROM,
509+
&field_reassign_with_default::FIELD_REASSIGN_WITH_DEFAULT,
508510
&format::USELESS_FORMAT,
509511
&formatting::POSSIBLE_MISSING_COMMA,
510512
&formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING,
@@ -992,6 +994,7 @@ pub fn register_plugins(store: &mut lint::LintStore, sess: &Session, conf: &Conf
992994
LintId::of(&enum_variants::MODULE_NAME_REPETITIONS),
993995
LintId::of(&enum_variants::PUB_ENUM_VARIANT_NAMES),
994996
LintId::of(&eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS),
997+
LintId::of(&field_reassign_with_default::FIELD_REASSIGN_WITH_DEFAULT),
995998
LintId::of(&functions::MUST_USE_CANDIDATE),
996999
LintId::of(&functions::TOO_MANY_LINES),
9971000
LintId::of(&if_not_else::IF_NOT_ELSE),

src/lintlist/mod.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ pub use lint::Lint;
66
pub use lint::LINT_LEVELS;
77

88
// begin lint list, do not remove this comment, it’s used in `update_lints`
9-
pub const ALL_LINTS: [Lint; 332] = [
9+
pub const ALL_LINTS: [Lint; 333] = [
1010
Lint {
1111
name: "absurd_extreme_comparisons",
1212
group: "correctness",
@@ -553,6 +553,13 @@ pub const ALL_LINTS: [Lint; 332] = [
553553
deprecation: None,
554554
module: "fallible_impl_from",
555555
},
556+
Lint {
557+
name: "field_reassign_with_default",
558+
group: "pedantic",
559+
desc: "instance initialized with Default should have its fields set in the initializer",
560+
deprecation: None,
561+
module: "field_reassign_with_default",
562+
},
556563
Lint {
557564
name: "filter_map",
558565
group: "pedantic",

0 commit comments

Comments
 (0)