@@ -218,7 +218,6 @@ mod large_const_arrays;
218
218
mod large_enum_variant;
219
219
mod large_stack_arrays;
220
220
mod len_zero;
221
- mod let_and_return;
222
221
mod let_if_seq;
223
222
mod let_underscore;
224
223
mod lifetimes;
@@ -256,7 +255,6 @@ mod needless_borrow;
256
255
mod needless_borrowed_ref;
257
256
mod needless_continue;
258
257
mod needless_pass_by_value;
259
- mod needless_return;
260
258
mod needless_update;
261
259
mod neg_cmp_op_on_partial_ord;
262
260
mod neg_multiply;
@@ -311,6 +309,7 @@ mod unnested_or_patterns;
311
309
mod unsafe_removed_from_name;
312
310
mod unused_io_amount;
313
311
mod unused_self;
312
+ mod unused_unit;
314
313
mod unwrap;
315
314
mod use_self;
316
315
mod useless_conversion;
@@ -587,7 +586,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
587
586
& large_stack_arrays:: LARGE_STACK_ARRAYS ,
588
587
& len_zero:: LEN_WITHOUT_IS_EMPTY ,
589
588
& len_zero:: LEN_ZERO ,
590
- & let_and_return :: LET_AND_RETURN ,
589
+ & returns :: LET_AND_RETURN ,
591
590
& let_if_seq:: USELESS_LET_IF_SEQ ,
592
591
& let_underscore:: LET_UNDERSCORE_LOCK ,
593
592
& let_underscore:: LET_UNDERSCORE_MUST_USE ,
@@ -727,7 +726,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
727
726
& needless_borrowed_ref:: NEEDLESS_BORROWED_REFERENCE ,
728
727
& needless_continue:: NEEDLESS_CONTINUE ,
729
728
& needless_pass_by_value:: NEEDLESS_PASS_BY_VALUE ,
730
- & needless_return :: NEEDLESS_RETURN ,
729
+ & returns :: NEEDLESS_RETURN ,
731
730
& needless_update:: NEEDLESS_UPDATE ,
732
731
& neg_cmp_op_on_partial_ord:: NEG_CMP_OP_ON_PARTIAL_ORD ,
733
732
& neg_multiply:: NEG_MULTIPLY ,
@@ -771,7 +770,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
771
770
& regex:: INVALID_REGEX ,
772
771
& regex:: TRIVIAL_REGEX ,
773
772
& repeat_once:: REPEAT_ONCE ,
774
- & returns :: UNUSED_UNIT ,
773
+ & unused_unit :: UNUSED_UNIT ,
775
774
& serde_api:: SERDE_API_MISUSE ,
776
775
& shadow:: SHADOW_REUSE ,
777
776
& shadow:: SHADOW_SAME ,
@@ -1026,9 +1025,8 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
1026
1025
store. register_early_pass ( || box misc_early:: MiscEarlyLints ) ;
1027
1026
store. register_early_pass ( || box redundant_closure_call:: RedundantClosureCall ) ;
1028
1027
store. register_late_pass ( || box redundant_closure_call:: RedundantClosureCall ) ;
1029
- store. register_early_pass ( || box returns:: Return ) ;
1030
- store. register_late_pass ( || box let_and_return:: LetReturn ) ;
1031
- store. register_late_pass ( || box needless_return:: NeedlessReturn ) ;
1028
+ store. register_early_pass ( || box unused_unit:: UnusedUnit ) ;
1029
+ store. register_late_pass ( || box returns:: Return ) ;
1032
1030
store. register_early_pass ( || box collapsible_if:: CollapsibleIf ) ;
1033
1031
store. register_early_pass ( || box items_after_statements:: ItemsAfterStatements ) ;
1034
1032
store. register_early_pass ( || box precedence:: Precedence ) ;
@@ -1286,7 +1284,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
1286
1284
LintId :: of( & large_enum_variant:: LARGE_ENUM_VARIANT ) ,
1287
1285
LintId :: of( & len_zero:: LEN_WITHOUT_IS_EMPTY ) ,
1288
1286
LintId :: of( & len_zero:: LEN_ZERO ) ,
1289
- LintId :: of( & let_and_return :: LET_AND_RETURN ) ,
1287
+ LintId :: of( & returns :: LET_AND_RETURN ) ,
1290
1288
LintId :: of( & let_underscore:: LET_UNDERSCORE_LOCK ) ,
1291
1289
LintId :: of( & lifetimes:: EXTRA_UNUSED_LIFETIMES ) ,
1292
1290
LintId :: of( & lifetimes:: NEEDLESS_LIFETIMES ) ,
@@ -1383,7 +1381,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
1383
1381
LintId :: of( & needless_bool:: BOOL_COMPARISON ) ,
1384
1382
LintId :: of( & needless_bool:: NEEDLESS_BOOL ) ,
1385
1383
LintId :: of( & needless_borrowed_ref:: NEEDLESS_BORROWED_REFERENCE ) ,
1386
- LintId :: of( & needless_return :: NEEDLESS_RETURN ) ,
1384
+ LintId :: of( & returns :: NEEDLESS_RETURN ) ,
1387
1385
LintId :: of( & needless_update:: NEEDLESS_UPDATE ) ,
1388
1386
LintId :: of( & neg_cmp_op_on_partial_ord:: NEG_CMP_OP_ON_PARTIAL_ORD ) ,
1389
1387
LintId :: of( & neg_multiply:: NEG_MULTIPLY ) ,
@@ -1416,7 +1414,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
1416
1414
LintId :: of( & regex:: INVALID_REGEX ) ,
1417
1415
LintId :: of( & regex:: TRIVIAL_REGEX ) ,
1418
1416
LintId :: of( & repeat_once:: REPEAT_ONCE ) ,
1419
- LintId :: of( & returns :: UNUSED_UNIT ) ,
1417
+ LintId :: of( & unused_unit :: UNUSED_UNIT ) ,
1420
1418
LintId :: of( & serde_api:: SERDE_API_MISUSE ) ,
1421
1419
LintId :: of( & single_component_path_imports:: SINGLE_COMPONENT_PATH_IMPORTS ) ,
1422
1420
LintId :: of( & slow_vector_initialization:: SLOW_VECTOR_INITIALIZATION ) ,
@@ -1502,7 +1500,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
1502
1500
LintId :: of( & inherent_to_string:: INHERENT_TO_STRING ) ,
1503
1501
LintId :: of( & len_zero:: LEN_WITHOUT_IS_EMPTY ) ,
1504
1502
LintId :: of( & len_zero:: LEN_ZERO ) ,
1505
- LintId :: of( & let_and_return :: LET_AND_RETURN ) ,
1503
+ LintId :: of( & returns :: LET_AND_RETURN ) ,
1506
1504
LintId :: of( & literal_representation:: INCONSISTENT_DIGIT_GROUPING ) ,
1507
1505
LintId :: of( & loops:: EMPTY_LOOP ) ,
1508
1506
LintId :: of( & loops:: FOR_KV_MAP ) ,
@@ -1545,7 +1543,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
1545
1543
LintId :: of( & misc_early:: MIXED_CASE_HEX_LITERALS ) ,
1546
1544
LintId :: of( & misc_early:: REDUNDANT_PATTERN ) ,
1547
1545
LintId :: of( & mut_reference:: UNNECESSARY_MUT_PASSED ) ,
1548
- LintId :: of( & needless_return :: NEEDLESS_RETURN ) ,
1546
+ LintId :: of( & returns :: NEEDLESS_RETURN ) ,
1549
1547
LintId :: of( & neg_multiply:: NEG_MULTIPLY ) ,
1550
1548
LintId :: of( & new_without_default:: NEW_WITHOUT_DEFAULT ) ,
1551
1549
LintId :: of( & non_expressive_names:: JUST_UNDERSCORES_AND_DIGITS ) ,
@@ -1557,7 +1555,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
1557
1555
LintId :: of( & redundant_field_names:: REDUNDANT_FIELD_NAMES ) ,
1558
1556
LintId :: of( & redundant_static_lifetimes:: REDUNDANT_STATIC_LIFETIMES ) ,
1559
1557
LintId :: of( & regex:: TRIVIAL_REGEX ) ,
1560
- LintId :: of( & returns :: UNUSED_UNIT ) ,
1558
+ LintId :: of( & unused_unit :: UNUSED_UNIT ) ,
1561
1559
LintId :: of( & single_component_path_imports:: SINGLE_COMPONENT_PATH_IMPORTS ) ,
1562
1560
LintId :: of( & strings:: STRING_LIT_AS_BYTES ) ,
1563
1561
LintId :: of( & tabs_in_doc_comments:: TABS_IN_DOC_COMMENTS ) ,
0 commit comments