Skip to content

Commit 1cd09c3

Browse files
authored
Embark standard lints v5 - require Rust 1.55 (#67)
1 parent 6432e18 commit 1cd09c3

File tree

2 files changed

+26
-4
lines changed

2 files changed

+26
-4
lines changed

lints.rs

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// BEGIN - Embark standard lints v0.4
1+
// BEGIN - Embark standard lints v5 for Rust 1.55+
22
// do not change or add/remove here, but one can add exceptions after this section
33
// for more info see: <https://github.com/EmbarkStudios/rust-ecosystem/issues/59>
44
#![deny(unsafe_code)]
@@ -9,6 +9,8 @@
99
clippy::checked_conversions,
1010
clippy::dbg_macro,
1111
clippy::debug_assert_with_mut_call,
12+
clippy::disallowed_method,
13+
clippy::disallowed_type,
1214
clippy::doc_markdown,
1315
clippy::empty_enum,
1416
clippy::enum_glob_use,
@@ -18,13 +20,17 @@
1820
clippy::explicit_into_iter_loop,
1921
clippy::fallible_impl_from,
2022
clippy::filter_map_next,
23+
clippy::flat_map_option,
2124
clippy::float_cmp_const,
2225
clippy::fn_params_excessive_bools,
26+
clippy::from_iter_instead_of_collect,
2327
clippy::if_let_mutex,
2428
clippy::implicit_clone,
2529
clippy::imprecise_flops,
2630
clippy::inefficient_to_string,
2731
clippy::invalid_upcast_comparisons,
32+
clippy::large_digit_groups,
33+
clippy::large_stack_arrays,
2834
clippy::large_types_passed_by_value,
2935
clippy::let_unit_value,
3036
clippy::linkedlist,
@@ -36,20 +42,25 @@
3642
clippy::map_unwrap_or,
3743
clippy::match_on_vec_items,
3844
clippy::match_same_arms,
45+
clippy::match_wild_err_arm,
3946
clippy::match_wildcard_for_single_variants,
4047
clippy::mem_forget,
4148
clippy::mismatched_target_os,
49+
clippy::missing_enforced_import_renames,
4250
clippy::mut_mut,
4351
clippy::mutex_integer,
4452
clippy::needless_borrow,
4553
clippy::needless_continue,
54+
clippy::needless_for_each,
4655
clippy::option_option,
4756
clippy::path_buf_push_overwrite,
4857
clippy::ptr_as_ptr,
58+
clippy::rc_mutex,
4959
clippy::ref_option_ref,
5060
clippy::rest_pat_in_fully_bound_structs,
5161
clippy::same_functions_in_if_condition,
5262
clippy::semicolon_if_nothing_returned,
63+
clippy::single_match_else,
5364
clippy::string_add_assign,
5465
clippy::string_add,
5566
clippy::string_lit_as_bytes,
@@ -66,6 +77,6 @@
6677
nonstandard_style,
6778
rust_2018_idioms
6879
)]
69-
// END - Embark standard lints v0.4
80+
// END - Embark standard lints v0.5 for Rust 1.55+
7081
// crate-specific exceptions:
7182
#![allow()]

lints.toml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[target.'cfg(all())']
44
rustflags = [
5-
# BEGIN - Embark standard lints v0.4
5+
# BEGIN - Embark standard lints v5 for Rust 1.55+
66
# do not change or add/remove here, but one can add exceptions after this section
77
# for more info see: <https://github.com/EmbarkStudios/rust-ecosystem/issues/59>
88
"-Dunsafe_code",
@@ -12,6 +12,8 @@ rustflags = [
1212
"-Wclippy::checked_conversions",
1313
"-Wclippy::dbg_macro",
1414
"-Wclippy::debug_assert_with_mut_call",
15+
"-Wclippy::disallowed_method",
16+
"-Wclippy::disallowed_type",
1517
"-Wclippy::doc_markdown",
1618
"-Wclippy::empty_enum",
1719
"-Wclippy::enum_glob_use",
@@ -21,13 +23,17 @@ rustflags = [
2123
"-Wclippy::explicit_into_iter_loop",
2224
"-Wclippy::fallible_impl_from",
2325
"-Wclippy::filter_map_next",
26+
"-Wclippy::flat_map_option",
2427
"-Wclippy::float_cmp_const",
2528
"-Wclippy::fn_params_excessive_bools",
29+
"-Wclippy::from_iter_instead_of_collect",
2630
"-Wclippy::if_let_mutex",
2731
"-Wclippy::implicit_clone",
2832
"-Wclippy::imprecise_flops",
2933
"-Wclippy::inefficient_to_string",
3034
"-Wclippy::invalid_upcast_comparisons",
35+
"-Wclippy::large_digit_groups",
36+
"-Wclippy::large_stack_arrays",
3137
"-Wclippy::large_types_passed_by_value",
3238
"-Wclippy::let_unit_value",
3339
"-Wclippy::linkedlist",
@@ -39,20 +45,25 @@ rustflags = [
3945
"-Wclippy::map_unwrap_or",
4046
"-Wclippy::match_on_vec_items",
4147
"-Wclippy::match_same_arms",
48+
"-Wclippy::match_wild_err_arm",
4249
"-Wclippy::match_wildcard_for_single_variants",
4350
"-Wclippy::mem_forget",
4451
"-Wclippy::mismatched_target_os",
52+
"-Wclippy::missing_enforced_import_renames",
4553
"-Wclippy::mut_mut",
4654
"-Wclippy::mutex_integer",
4755
"-Wclippy::needless_borrow",
4856
"-Wclippy::needless_continue",
57+
"-Wclippy::needless_for_each",
4958
"-Wclippy::option_option",
5059
"-Wclippy::path_buf_push_overwrite",
5160
"-Wclippy::ptr_as_ptr",
61+
"-Wclippy::rc_mutex",
5262
"-Wclippy::ref_option_ref",
5363
"-Wclippy::rest_pat_in_fully_bound_structs",
5464
"-Wclippy::same_functions_in_if_condition",
5565
"-Wclippy::semicolon_if_nothing_returned",
66+
"-Wclippy::single_match_else",
5667
"-Wclippy::string_add_assign",
5768
"-Wclippy::string_add",
5869
"-Wclippy::string_lit_as_bytes",
@@ -68,5 +79,5 @@ rustflags = [
6879
"-Wfuture_incompatible",
6980
"-Wnonstandard_style",
7081
"-Wrust_2018_idioms",
71-
# END - Embark standard lints v0.4
82+
# END - Embark standard lints v5 for Rust 1.55+
7283
]

0 commit comments

Comments
 (0)