@@ -6,11 +6,157 @@ document.
6
6
7
7
## Unreleased / In Rust Nightly
8
8
9
- [ 7c21f91b...master] ( https://github.com/rust-lang/rust-clippy/compare/7c21f91b...master )
9
+ [ d7b5cbf0...master] ( https://github.com/rust-lang/rust-clippy/compare/d7b5cbf0...master )
10
+
11
+ ## Rust 1.63
12
+
13
+ Current stable, released 2022-08-11
14
+
15
+ [ 7c21f91b...d7b5cbf0] ( https://github.com/rust-lang/rust-clippy/compare/7c21f91b...d7b5cbf0 )
16
+
17
+ ### New Lints
18
+
19
+ * [ ` borrow_deref_ref ` ]
20
+ [ #7930 ] ( https://github.com/rust-lang/rust-clippy/pull/7930 )
21
+ * [ ` doc_link_with_quotes ` ]
22
+ [ #8385 ] ( https://github.com/rust-lang/rust-clippy/pull/8385 )
23
+ * [ ` no_effect_replace ` ]
24
+ [ #8754 ] ( https://github.com/rust-lang/rust-clippy/pull/8754 )
25
+ * [ ` rc_clone_in_vec_init ` ]
26
+ [ #8769 ] ( https://github.com/rust-lang/rust-clippy/pull/8769 )
27
+ * [ ` derive_partial_eq_without_eq ` ]
28
+ [ #8796 ] ( https://github.com/rust-lang/rust-clippy/pull/8796 )
29
+ * [ ` mismatching_type_param_order ` ]
30
+ [ #8831 ] ( https://github.com/rust-lang/rust-clippy/pull/8831 )
31
+ * [ ` duplicate_mod ` ] [ #8832 ] ( https://github.com/rust-lang/rust-clippy/pull/8832 )
32
+ * [ ` unused_rounding ` ]
33
+ [ #8866 ] ( https://github.com/rust-lang/rust-clippy/pull/8866 )
34
+ * [ ` get_first ` ] [ #8882 ] ( https://github.com/rust-lang/rust-clippy/pull/8882 )
35
+ * [ ` swap_ptr_to_ref ` ]
36
+ [ #8916 ] ( https://github.com/rust-lang/rust-clippy/pull/8916 )
37
+ * [ ` almost_complete_letter_range ` ]
38
+ [ #8918 ] ( https://github.com/rust-lang/rust-clippy/pull/8918 )
39
+ * [ ` needless_parens_on_range_literals ` ]
40
+ [ #8933 ] ( https://github.com/rust-lang/rust-clippy/pull/8933 )
41
+ * [ ` as_underscore ` ] [ #8934 ] ( https://github.com/rust-lang/rust-clippy/pull/8934 )
42
+
43
+ ### Moves and Deprecations
44
+
45
+ * Rename ` eval_order_dependence ` to [ ` mixed_read_write_in_expression ` ] , move to
46
+ ` nursery ` [ #8621 ] ( https://github.com/rust-lang/rust-clippy/pull/8621 )
47
+
48
+ ### Enhancements
49
+
50
+ * [ ` undocumented_unsafe_blocks ` ] : Now also lints on unsafe trait implementations
51
+ [ #8761 ] ( https://github.com/rust-lang/rust-clippy/pull/8761 )
52
+ * [ ` empty_line_after_outer_attr ` ] : Now also lints on argumentless macros
53
+ [ #8790 ] ( https://github.com/rust-lang/rust-clippy/pull/8790 )
54
+ * [ ` expect_used ` ] : Now can be disabled in tests with the ` allow-expect-in-tests `
55
+ option [ #8802 ] ( https://github.com/rust-lang/rust-clippy/pull/8802 )
56
+ * [ ` unwrap_used ` ] : Now can be disabled in tests with the ` allow-unwrap-in-tests `
57
+ option [ #8802 ] ( https://github.com/rust-lang/rust-clippy/pull/8802 )
58
+ * [ ` disallowed_methods ` ] : Now also lints indirect usages
59
+ [ #8852 ] ( https://github.com/rust-lang/rust-clippy/pull/8852 )
60
+ * [ ` get_last_with_len ` ] : Now also lints ` VecDeque ` and any deref to slice
61
+ [ #8862 ] ( https://github.com/rust-lang/rust-clippy/pull/8862 )
62
+ * [ ` manual_range_contains ` ] : Now also lints on chains of ` && ` and ` || `
63
+ [ #8884 ] ( https://github.com/rust-lang/rust-clippy/pull/8884 )
64
+ * [ ` rc_clone_in_vec_init ` ] : Now also lints on ` Weak `
65
+ [ #8885 ] ( https://github.com/rust-lang/rust-clippy/pull/8885 )
66
+ * [ ` dbg_macro ` ] : Introduce ` allow-dbg-in-tests ` config option
67
+ [ #8897 ] ( https://github.com/rust-lang/rust-clippy/pull/8897 )
68
+ * [ ` use_self ` ] : Now also lints on ` TupleStruct ` and ` Struct ` patterns
69
+ [ #8899 ] ( https://github.com/rust-lang/rust-clippy/pull/8899 )
70
+ * [ ` manual_find_map ` ] and [ ` manual_filter_map ` ] : Now also lints on more complex
71
+ method chains inside ` map `
72
+ [ #8930 ] ( https://github.com/rust-lang/rust-clippy/pull/8930 )
73
+ * [ ` needless_return ` ] : Now also lints on macro expressions in return statements
74
+ [ #8932 ] ( https://github.com/rust-lang/rust-clippy/pull/8932 )
75
+ * [ ` doc_markdown ` ] : Users can now indicate, that the ` doc-valid-idents ` config
76
+ should extend the default and not replace it
77
+ [ #8944 ] ( https://github.com/rust-lang/rust-clippy/pull/8944 )
78
+ * [ ` disallowed_names ` ] : Users can now indicate, that the ` disallowed-names `
79
+ config should extend the default and not replace it
80
+ [ #8944 ] ( https://github.com/rust-lang/rust-clippy/pull/8944 )
81
+ * [ ` never_loop ` ] : Now checks for ` continue ` in struct expression
82
+ [ #9002 ] ( https://github.com/rust-lang/rust-clippy/pull/9002 )
83
+
84
+ ### False Positive Fixes
85
+
86
+ * [ ` useless_transmute ` ] : No longer lints on types with erased regions
87
+ [ #8564 ] ( https://github.com/rust-lang/rust-clippy/pull/8564 )
88
+ * [ ` vec_init_then_push ` ] : No longer lints when further extended
89
+ [ #8699 ] ( https://github.com/rust-lang/rust-clippy/pull/8699 )
90
+ * [ ` cmp_owned ` ] : No longer lints on ` From::from ` for ` Copy ` types
91
+ [ #8807 ] ( https://github.com/rust-lang/rust-clippy/pull/8807 )
92
+ * [ ` redundant_allocation ` ] : No longer lints on fat pointers that would become
93
+ thin pointers [ #8813 ] ( https://github.com/rust-lang/rust-clippy/pull/8813 )
94
+ * [ ` derive_partial_eq_without_eq ` ] :
95
+ * Handle differing predicates applied by ` #[derive(PartialEq)] ` and
96
+ ` #[derive(Eq)] `
97
+ [ #8869 ] ( https://github.com/rust-lang/rust-clippy/pull/8869 )
98
+ * No longer lints on non-public types and better handles generics
99
+ [ #8950 ] ( https://github.com/rust-lang/rust-clippy/pull/8950 )
100
+ * [ ` empty_line_after_outer_attr ` ] : No longer lints empty lines in inner
101
+ string values [ #8892 ] ( https://github.com/rust-lang/rust-clippy/pull/8892 )
102
+ * [ ` branches_sharing_code ` ] : No longer lints when using different binding names
103
+ [ #8901 ] ( https://github.com/rust-lang/rust-clippy/pull/8901 )
104
+ * [ ` significant_drop_in_scrutinee ` ] : No longer lints on Try ` ? ` and ` await `
105
+ desugared expressions [ #8902 ] ( https://github.com/rust-lang/rust-clippy/pull/8902 )
106
+ * [ ` checked_conversions ` ] : No longer lints in ` const ` contexts
107
+ [ #8907 ] ( https://github.com/rust-lang/rust-clippy/pull/8907 )
108
+ * [ ` iter_overeager_cloned ` ] : No longer lints on ` .cloned().flatten() ` when
109
+ ` T::Item ` doesn't implement ` IntoIterator `
110
+ [ #8960 ] ( https://github.com/rust-lang/rust-clippy/pull/8960 )
111
+
112
+ ### Suggestion Fixes/Improvements
113
+
114
+ * [ ` vec_init_then_push ` ] : Suggest to remove ` mut ` binding when possible
115
+ [ #8699 ] ( https://github.com/rust-lang/rust-clippy/pull/8699 )
116
+ * [ ` manual_range_contains ` ] : Fix suggestion for integers with different signs
117
+ [ #8763 ] ( https://github.com/rust-lang/rust-clippy/pull/8763 )
118
+ * [ ` identity_op ` ] : Add parenthesis to suggestions where required
119
+ [ #8786 ] ( https://github.com/rust-lang/rust-clippy/pull/8786 )
120
+ * [ ` cast_lossless ` ] : No longer gives wrong suggestion on ` usize ` /` isize ` ->` f64 `
121
+ [ #8778 ] ( https://github.com/rust-lang/rust-clippy/pull/8778 )
122
+ * [ ` rc_clone_in_vec_init ` ] : Add suggestion
123
+ [ #8814 ] ( https://github.com/rust-lang/rust-clippy/pull/8814 )
124
+ * The "unknown field" error messages for config files now wraps the field names
125
+ [ #8823 ] ( https://github.com/rust-lang/rust-clippy/pull/8823 )
126
+ * [ ` cast_abs_to_unsigned ` ] : Do not remove cast if it's required
127
+ [ #8876 ] ( https://github.com/rust-lang/rust-clippy/pull/8876 )
128
+ * [ ` significant_drop_in_scrutinee ` ] : Improve lint message for types that are not
129
+ references and not trivially clone-able
130
+ [ #8902 ] ( https://github.com/rust-lang/rust-clippy/pull/8902 )
131
+ * [ ` for_loops_over_fallibles ` ] : Now suggests the correct variant of ` iter() ` ,
132
+ ` iter_mut() ` or ` into_iter() `
133
+ [ #8941 ] ( https://github.com/rust-lang/rust-clippy/pull/8941 )
134
+
135
+ ### ICE Fixes
136
+
137
+ * Fix ICE in [ ` let_unit_value ` ] when calling a ` static ` /` const ` callable type
138
+ [ #8835 ] ( https://github.com/rust-lang/rust-clippy/pull/8835 )
139
+ * Fix ICEs on callable ` static ` /` const ` s
140
+ [ #8896 ] ( https://github.com/rust-lang/rust-clippy/pull/8896 )
141
+ * [ ` needless_late_init ` ]
142
+ [ #8912 ] ( https://github.com/rust-lang/rust-clippy/pull/8912 )
143
+ * Fix ICE in shadow lints
144
+ [ #8913 ] ( https://github.com/rust-lang/rust-clippy/pull/8913 )
145
+
146
+ ### Documentation Improvements
147
+
148
+ * Clippy has a [ Book] ( https://doc.rust-lang.org/nightly/clippy/ ) now!
149
+ [ #7359 ] ( https://github.com/rust-lang/rust-clippy/pull/7359 )
150
+ * Add a * copy lint name* -button to Clippy's lint list
151
+ [ #8839 ] ( https://github.com/rust-lang/rust-clippy/pull/8839 )
152
+ * Display past names of renamed lints on Clippy's lint list
153
+ [ #8843 ] ( https://github.com/rust-lang/rust-clippy/pull/8843 )
154
+ * Add the ability to show the lint output in the lint list
155
+ [ #8947 ] ( https://github.com/rust-lang/rust-clippy/pull/8947 )
10
156
11
157
## Rust 1.62
12
158
13
- Current stable, released 2022-06-30
159
+ Released 2022-06-30
14
160
15
161
[ d0cf3481...7c21f91b] ( https://github.com/rust-lang/rust-clippy/compare/d0cf3481...7c21f91b )
16
162
@@ -3481,6 +3627,7 @@ Released 2018-09-13
3481
3627
[ `cast_ref_to_mut` ] : https://rust-lang.github.io/rust-clippy/master/index.html#cast_ref_to_mut
3482
3628
[ `cast_sign_loss` ] : https://rust-lang.github.io/rust-clippy/master/index.html#cast_sign_loss
3483
3629
[ `cast_slice_different_sizes` ] : https://rust-lang.github.io/rust-clippy/master/index.html#cast_slice_different_sizes
3630
+ [ `cast_slice_from_raw_parts` ] : https://rust-lang.github.io/rust-clippy/master/index.html#cast_slice_from_raw_parts
3484
3631
[ `char_lit_as_u8` ] : https://rust-lang.github.io/rust-clippy/master/index.html#char_lit_as_u8
3485
3632
[ `chars_last_cmp` ] : https://rust-lang.github.io/rust-clippy/master/index.html#chars_last_cmp
3486
3633
[ `chars_next_cmp` ] : https://rust-lang.github.io/rust-clippy/master/index.html#chars_next_cmp
@@ -3496,6 +3643,7 @@ Released 2018-09-13
3496
3643
[ `collapsible_else_if` ] : https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_else_if
3497
3644
[ `collapsible_if` ] : https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_if
3498
3645
[ `collapsible_match` ] : https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
3646
+ [ `collapsible_str_replace` ] : https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_str_replace
3499
3647
[ `comparison_chain` ] : https://rust-lang.github.io/rust-clippy/master/index.html#comparison_chain
3500
3648
[ `comparison_to_empty` ] : https://rust-lang.github.io/rust-clippy/master/index.html#comparison_to_empty
3501
3649
[ `const_static_lifetime` ] : https://rust-lang.github.io/rust-clippy/master/index.html#const_static_lifetime
@@ -3656,6 +3804,8 @@ Released 2018-09-13
3656
3804
[ `iter_not_returning_iterator` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_not_returning_iterator
3657
3805
[ `iter_nth` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_nth
3658
3806
[ `iter_nth_zero` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_nth_zero
3807
+ [ `iter_on_empty_collections` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_on_empty_collections
3808
+ [ `iter_on_single_items` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_on_single_items
3659
3809
[ `iter_overeager_cloned` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_overeager_cloned
3660
3810
[ `iter_skip_next` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_skip_next
3661
3811
[ `iter_with_drain` ] : https://rust-lang.github.io/rust-clippy/master/index.html#iter_with_drain
@@ -3697,6 +3847,7 @@ Released 2018-09-13
3697
3847
[ `manual_saturating_arithmetic` ] : https://rust-lang.github.io/rust-clippy/master/index.html#manual_saturating_arithmetic
3698
3848
[ `manual_split_once` ] : https://rust-lang.github.io/rust-clippy/master/index.html#manual_split_once
3699
3849
[ `manual_str_repeat` ] : https://rust-lang.github.io/rust-clippy/master/index.html#manual_str_repeat
3850
+ [ `manual_string_new` ] : https://rust-lang.github.io/rust-clippy/master/index.html#manual_string_new
3700
3851
[ `manual_strip` ] : https://rust-lang.github.io/rust-clippy/master/index.html#manual_strip
3701
3852
[ `manual_swap` ] : https://rust-lang.github.io/rust-clippy/master/index.html#manual_swap
3702
3853
[ `manual_unwrap_or` ] : https://rust-lang.github.io/rust-clippy/master/index.html#manual_unwrap_or
@@ -3747,6 +3898,7 @@ Released 2018-09-13
3747
3898
[ `module_name_repetitions` ] : https://rust-lang.github.io/rust-clippy/master/index.html#module_name_repetitions
3748
3899
[ `modulo_arithmetic` ] : https://rust-lang.github.io/rust-clippy/master/index.html#modulo_arithmetic
3749
3900
[ `modulo_one` ] : https://rust-lang.github.io/rust-clippy/master/index.html#modulo_one
3901
+ [ `multi_assignments` ] : https://rust-lang.github.io/rust-clippy/master/index.html#multi_assignments
3750
3902
[ `multiple_crate_versions` ] : https://rust-lang.github.io/rust-clippy/master/index.html#multiple_crate_versions
3751
3903
[ `multiple_inherent_impl` ] : https://rust-lang.github.io/rust-clippy/master/index.html#multiple_inherent_impl
3752
3904
[ `must_use_candidate` ] : https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate
@@ -3827,6 +3979,7 @@ Released 2018-09-13
3827
3979
[ `partialeq_to_none` ] : https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_to_none
3828
3980
[ `path_buf_push_overwrite` ] : https://rust-lang.github.io/rust-clippy/master/index.html#path_buf_push_overwrite
3829
3981
[ `pattern_type_mismatch` ] : https://rust-lang.github.io/rust-clippy/master/index.html#pattern_type_mismatch
3982
+ [ `positional_named_format_parameters` ] : https://rust-lang.github.io/rust-clippy/master/index.html#positional_named_format_parameters
3830
3983
[ `possible_missing_comma` ] : https://rust-lang.github.io/rust-clippy/master/index.html#possible_missing_comma
3831
3984
[ `precedence` ] : https://rust-lang.github.io/rust-clippy/master/index.html#precedence
3832
3985
[ `print_in_format_impl` ] : https://rust-lang.github.io/rust-clippy/master/index.html#print_in_format_impl
@@ -3872,6 +4025,7 @@ Released 2018-09-13
3872
4025
[ `replace_consts` ] : https://rust-lang.github.io/rust-clippy/master/index.html#replace_consts
3873
4026
[ `rest_pat_in_fully_bound_structs` ] : https://rust-lang.github.io/rust-clippy/master/index.html#rest_pat_in_fully_bound_structs
3874
4027
[ `result_expect_used` ] : https://rust-lang.github.io/rust-clippy/master/index.html#result_expect_used
4028
+ [ `result_large_err` ] : https://rust-lang.github.io/rust-clippy/master/index.html#result_large_err
3875
4029
[ `result_map_or_into_option` ] : https://rust-lang.github.io/rust-clippy/master/index.html#result_map_or_into_option
3876
4030
[ `result_map_unit_fn` ] : https://rust-lang.github.io/rust-clippy/master/index.html#result_map_unit_fn
3877
4031
[ `result_map_unwrap_or_else` ] : https://rust-lang.github.io/rust-clippy/master/index.html#result_map_unwrap_or_else
@@ -3930,6 +4084,7 @@ Released 2018-09-13
3930
4084
[ `suspicious_op_assign_impl` ] : https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_op_assign_impl
3931
4085
[ `suspicious_operation_groupings` ] : https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_operation_groupings
3932
4086
[ `suspicious_splitn` ] : https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_splitn
4087
+ [ `suspicious_to_owned` ] : https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_to_owned
3933
4088
[ `suspicious_unary_op_formatting` ] : https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_unary_op_formatting
3934
4089
[ `swap_ptr_to_ref` ] : https://rust-lang.github.io/rust-clippy/master/index.html#swap_ptr_to_ref
3935
4090
[ `tabs_in_doc_comments` ] : https://rust-lang.github.io/rust-clippy/master/index.html#tabs_in_doc_comments
@@ -4002,6 +4157,7 @@ Released 2018-09-13
4002
4157
[ `unused_collect` ] : https://rust-lang.github.io/rust-clippy/master/index.html#unused_collect
4003
4158
[ `unused_io_amount` ] : https://rust-lang.github.io/rust-clippy/master/index.html#unused_io_amount
4004
4159
[ `unused_label` ] : https://rust-lang.github.io/rust-clippy/master/index.html#unused_label
4160
+ [ `unused_peekable` ] : https://rust-lang.github.io/rust-clippy/master/index.html#unused_peekable
4005
4161
[ `unused_rounding` ] : https://rust-lang.github.io/rust-clippy/master/index.html#unused_rounding
4006
4162
[ `unused_self` ] : https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
4007
4163
[ `unused_unit` ] : https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit
0 commit comments