Skip to content

Commit a35e223

Browse files
Henri Lunnikivihegza
authored andcommitted
Run update_lints
1 parent 7d0450f commit a35e223

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1712,6 +1712,7 @@ Released 2018-09-13
17121712
[`extend_from_slice`]: https://rust-lang.github.io/rust-clippy/master/index.html#extend_from_slice
17131713
[`extra_unused_lifetimes`]: https://rust-lang.github.io/rust-clippy/master/index.html#extra_unused_lifetimes
17141714
[`fallible_impl_from`]: https://rust-lang.github.io/rust-clippy/master/index.html#fallible_impl_from
1715+
[`field_reassign_with_default`]: https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
17151716
[`filetype_is_file`]: https://rust-lang.github.io/rust-clippy/master/index.html#filetype_is_file
17161717
[`filter_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#filter_map
17171718
[`filter_map_next`]: https://rust-lang.github.io/rust-clippy/master/index.html#filter_map_next

clippy_lints/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,7 @@ mod excessive_bools;
198198
mod exit;
199199
mod explicit_write;
200200
mod fallible_impl_from;
201+
mod field_reassign_with_default;
201202
mod float_equality_without_abs;
202203
mod float_literal;
203204
mod floating_point_arithmetic;
@@ -569,6 +570,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
569570
&exit::EXIT,
570571
&explicit_write::EXPLICIT_WRITE,
571572
&fallible_impl_from::FALLIBLE_IMPL_FROM,
573+
&field_reassign_with_default::FIELD_REASSIGN_WITH_DEFAULT,
572574
&float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS,
573575
&float_literal::EXCESSIVE_PRECISION,
574576
&float_literal::LOSSY_FLOAT_LITERAL,
@@ -1206,6 +1208,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
12061208
LintId::of(&eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS),
12071209
LintId::of(&excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS),
12081210
LintId::of(&excessive_bools::STRUCT_EXCESSIVE_BOOLS),
1211+
LintId::of(&field_reassign_with_default::FIELD_REASSIGN_WITH_DEFAULT),
12091212
LintId::of(&functions::MUST_USE_CANDIDATE),
12101213
LintId::of(&functions::TOO_MANY_LINES),
12111214
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
@@ -613,6 +613,13 @@ vec![
613613
deprecation: None,
614614
module: "fallible_impl_from",
615615
},
616+
Lint {
617+
name: "field_reassign_with_default",
618+
group: "pedantic",
619+
desc: "instance initialized with Default should have its fields set in the initializer",
620+
deprecation: None,
621+
module: "field_reassign_with_default",
622+
},
616623
Lint {
617624
name: "filetype_is_file",
618625
group: "restriction",

0 commit comments

Comments
 (0)