@@ -447,59 +447,80 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
447
447
// begin deprecated lints, do not remove this comment, it’s used in `update_lints`
448
448
store. register_removed (
449
449
"clippy::should_assert_eq" ,
450
- "`assert!()` will be more flexible with RFC 2011" ,
450
+ "This used to check for `assert!(a == b)` and recommend replacement with \
451
+ `assert_eq!(a, b)`, but this is no longer needed after \
452
+ [RFC 2011](https://rust-lang.github.io/rfcs/2011-generic-assert.html).",
451
453
) ;
452
454
store. register_removed (
453
455
"clippy::extend_from_slice" ,
454
- "`.extend_from_slice(_)` is a faster way to extend a Vec by a slice" ,
456
+ "This used to check for `Vec::extend`, which was slower than \
457
+ `Vec::extend_from_slice`. Thanks to specialization, this is no longer true.",
455
458
) ;
456
459
store. register_removed (
457
460
"clippy::range_step_by_zero" ,
458
- "`iterator.step_by(0)` panics nowadays" ,
461
+ "`Range::step_by(0)` used to be linted since it's \
462
+ an infinite iterator, which is better expressed by `iter::repeat`, \
463
+ but the method has been removed for `Iterator::step_by` which panics \
464
+ if given a zero",
459
465
) ;
460
466
store. register_removed (
461
467
"clippy::unstable_as_slice" ,
462
- "`Vec::as_slice` has been stabilized in 1.7" ,
468
+ "This used to check for `Vec::as_slice`, which was unstable with good \
469
+ stable alternatives. `Vec::as_slice` has now been stabilized.",
463
470
) ;
464
471
store. register_removed (
465
472
"clippy::unstable_as_mut_slice" ,
466
- "`Vec::as_mut_slice` has been stabilized in 1.7" ,
473
+ "This used to check for `Vec::as_mut_slice`, which was unstable with good \
474
+ stable alternatives. `Vec::as_mut_slice` has now been stabilized.",
467
475
) ;
468
476
store. register_removed (
469
477
"clippy::misaligned_transmute" ,
470
- "this lint has been split into cast_ptr_alignment and transmute_ptr_to_ptr" ,
478
+ "This lint should never have applied to non-pointer types, as transmuting \
479
+ between non-pointer types of differing alignment is well-defined behavior \
480
+ (it's semantically equivalent to a memcpy). This lint has thus been \
481
+ refactored into two separate lints: `clippy::cast_ptr_alignment` and \
482
+ `clippy::transmute_ptr_to_ptr`.",
471
483
) ;
472
484
store. register_removed (
473
485
"clippy::assign_ops" ,
474
- "using compound assignment operators (e.g., `+=`) is harmless" ,
486
+ "This lint is too subjective, not having a good reason for being in clippy. \
487
+ Additionally, compound assignment operators may be overloaded separately \
488
+ from their non-assigning counterparts, so this lint may suggest a change \
489
+ in behavior or the code may not compile.",
475
490
) ;
476
491
store. register_removed (
477
492
"clippy::if_let_redundant_pattern_matching" ,
478
- "this lint has been changed to redundant_pattern_matching" ,
493
+ "The original rule will only lint for `if let`. After making it support \
494
+ to lint `match`, naming as `if let` is not suitable for it. So, this lint \
495
+ is deprecated.",
479
496
) ;
480
497
store. register_removed (
481
498
"clippy::unsafe_vector_initialization" ,
482
- "the replacement suggested by this lint had substantially different behavior" ,
499
+ "This lint used to suggest replacing \
500
+ `let mut vec = Vec::with_capacity(n); vec.set_len(n);` with \
501
+ `let vec = vec![0; n];`. The replacement has very different \
502
+ performance characteristics so the lint is deprecated.",
483
503
) ;
484
504
store. register_removed (
485
505
"clippy::unused_collect" ,
486
- "`collect` has been marked as #[must_use] in rustc and that covers all cases of this lint " ,
506
+ "This lint has been superseded by #[must_use] in rustc. " ,
487
507
) ;
488
508
store. register_removed (
489
509
"clippy::replace_consts" ,
490
- "associated-constants `MIN`/`MAX` of integers are preferred to `{min,max}_value()` and module constants" ,
510
+ "associated-constants `MIN`/`MAX` of integers are preferred to \
511
+ `{min,max}_value()` and module constants",
491
512
) ;
492
513
store. register_removed (
493
514
"clippy::regex_macro" ,
494
515
"the regex! macro has been removed from the regex crate in 2018" ,
495
516
) ;
496
517
store. register_removed (
497
518
"clippy::find_map" ,
498
- "this lint has been replaced by `manual_find_map`, a more specific lint" ,
519
+ "This lint has been replaced by `manual_find_map`, a more specific lint. " ,
499
520
) ;
500
521
store. register_removed (
501
522
"clippy::filter_map" ,
502
- "this lint has been replaced by `manual_filter_map`, a more specific lint" ,
523
+ "This lint has been replaced by `manual_filter_map`, a more specific lint. " ,
503
524
) ;
504
525
// end deprecated lints, do not remove this comment, it’s used in `update_lints`
505
526
0 commit comments