Skip to content

Commit 099dc7f

Browse files
author
Henri Lunnikivi
committed
Run update_lints
1 parent afef61f commit 099dc7f

File tree

4 files changed

+12
-1
lines changed

4 files changed

+12
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1489,6 +1489,7 @@ Released 2018-09-13
14891489
[`extend_from_slice`]: https://rust-lang.github.io/rust-clippy/master/index.html#extend_from_slice
14901490
[`extra_unused_lifetimes`]: https://rust-lang.github.io/rust-clippy/master/index.html#extra_unused_lifetimes
14911491
[`fallible_impl_from`]: https://rust-lang.github.io/rust-clippy/master/index.html#fallible_impl_from
1492+
[`field_reassign_with_default`]: https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
14921493
[`filetype_is_file`]: https://rust-lang.github.io/rust-clippy/master/index.html#filetype_is_file
14931494
[`filter_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#filter_map
14941495
[`filter_map_next`]: https://rust-lang.github.io/rust-clippy/master/index.html#filter_map_next

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 350 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)
8+
[There are over 351 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)
99

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

clippy_lints/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,7 @@ mod excessive_bools;
193193
mod exit;
194194
mod explicit_write;
195195
mod fallible_impl_from;
196+
mod field_reassign_with_default;
196197
mod float_literal;
197198
mod floating_point_arithmetic;
198199
mod format;
@@ -549,6 +550,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
549550
&exit::EXIT,
550551
&explicit_write::EXPLICIT_WRITE,
551552
&fallible_impl_from::FALLIBLE_IMPL_FROM,
553+
&field_reassign_with_default::FIELD_REASSIGN_WITH_DEFAULT,
552554
&float_literal::EXCESSIVE_PRECISION,
553555
&float_literal::LOSSY_FLOAT_LITERAL,
554556
&floating_point_arithmetic::IMPRECISE_FLOPS,
@@ -1154,6 +1156,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
11541156
LintId::of(&eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS),
11551157
LintId::of(&excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS),
11561158
LintId::of(&excessive_bools::STRUCT_EXCESSIVE_BOOLS),
1159+
LintId::of(&field_reassign_with_default::FIELD_REASSIGN_WITH_DEFAULT),
11571160
LintId::of(&functions::MUST_USE_CANDIDATE),
11581161
LintId::of(&functions::TOO_MANY_LINES),
11591162
LintId::of(&if_not_else::IF_NOT_ELSE),

src/lintlist/mod.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -598,6 +598,13 @@ pub static ref ALL_LINTS: Vec<Lint> = vec![
598598
deprecation: None,
599599
module: "fallible_impl_from",
600600
},
601+
Lint {
602+
name: "field_reassign_with_default",
603+
group: "pedantic",
604+
desc: "instance initialized with Default should have its fields set in the initializer",
605+
deprecation: None,
606+
module: "field_reassign_with_default",
607+
},
601608
Lint {
602609
name: "filetype_is_file",
603610
group: "restriction",

0 commit comments

Comments
 (0)