about summary refs log tree commit diff
path: root/clippy_lints/src/deprecated_lints.rs
AgeCommit message (Collapse)AuthorLines
2025-02-07Deprecate redundant lint `option_map_or_err_ok` and take `manual_ok_or` out ↵dswij-0/+2
of pedantic (#14027) While extending the `option_map_or_err_ok` lint (warn by default, "style") to recognize η-expanded forms of `Ok`, as in ```rust // Should suggest `opt.ok_or("foobar")` let _ = opt.map_or(Err("foobar"), |x| Ok(x)); ``` I discovered that the `manual_ok_or` lint (allow by default, "pedantic") already covered exactly the cases handled by `option_map_or_err_ok`, including the one I was adding. Apparently, `option_map_or_err_ok` was added without realizing that the lint already existed under the `manual_ok_or` name. As a matter of fact, artifacts of this second lint were even present in the first lint `stderr` file and went unnoticed for more than a year. This PR: - deprecates `option_map_or_err_ok` with a message saying to use `manual_ok_or` - moves `manual_ok_or` from "pedantic" to "style" (the category in which `option_map_or_err_ok` was) In addition, I think that this lint, which is short, machine applicable, and leads to shorter and clearer code with less arguments (`Ok` disappears) and the removal of one level of call (`Err(x)` is replaced by `x`), is a reason by itself to be in "style". changelog: [`option_map_or_err_ok` and `manual_ok_or`]: move `manual_ok_or` from "pedantic" to "style", and deprecate the redundant style lint `option_map_or_err_ok`.
2025-01-26remove `clippy::double_neg`Kalle Wachsmuth-0/+2
2025-01-23Deprecate the `option_map_or_err_ok` lintSamuel Tardieu-0/+2
2024-12-02Drop uplifted `clippy::fn_address_comparisons`Urgau-0/+2
2024-10-28New lint: `dangling_pointers_from_temporaries`Pavel Grigorenko-1/+1
2024-08-08Merge commit 'cb806113e0f83a8f9b47d35b453b676543bcc40e' into ↵Philipp Krones-228/+166
clippy-subtree-update
2024-06-13Merge commit '3e5a02b13b1244545454752c6629b767522a44b1' into ↵Philipp Krones-0/+26
clippy-subtree-update
2022-06-30Merge commit '0cb0f7636851f9fcc57085cf80197a2ef6db098f' into clippyupPhilipp Krones-5/+10
2022-05-21Merge 'rust-clippy/master' into clippyupxFrednet-1/+0
2021-12-06Merge commit 'a5d597637dcb78dc73f93561ce474f23d4177c35' into clippyupflip1995-0/+16
2021-11-04Merge commit 'e18101137866b79045fee0ef996e696e68c920b4' into clippyupflip1995-0/+3
2021-07-29Merge commit '0cce3f643bfcbb92d5a1bb71858c9cbaff749d6b' into clippyupflip1995-32/+64
2021-07-01Merge commit '61eb38aeda6cb54b93b872bf503d70084c4d621c' into clippyupflip1995-2/+2
2021-06-03Merge commit '3ae8faff4d46ad92f194c2a4b941c3152a701b31' into clippyupflip1995-0/+19
2021-05-20Merge commit '9e3cd88718cd1912a515d26dbd9c4019fd5a9577' into clippyupflip1995-2/+9
2021-04-22Merge commit '98e2b9f25b6db4b2680a3d388456d9f95cb28344' into clippyupflip1995-61/+7
2021-01-30Merge commit '95c0459217d1661edfa794c8bb122452b92fb485' into clippyupflip1995-0/+9
2021-01-16Deprecate unknown_clippy_lintsflip1995-0/+13
This is now handled by unknown_lints
2020-12-06Merge commit 'c1664c50b27a51f7a78c93ba65558e7c33eabee6' into clippyupflip1995-20/+0
2020-11-23Merge commit '3e7c6dec244539970b593824334876f8b6ed0b18' into clippyupflip1995-0/+5
2020-10-28Merge commit '645ef505da378b6f810b1567806d1bcc2856395f' into clippyupEduardo Broto-0/+9
2020-10-02Deprecate clippy lintMichael Howell-0/+9
2020-07-26Merge commit 'da5a6fb1b65ec6581a67e942a3850f6bc15a552c' into clippyupflip1995-1/+1
2020-07-14Merge commit '2ca58e7dda4a9eb142599638c59dc04d15961175' into clippyupflip1995-1/+9
2020-03-29Deprecate REPLACE_CONSTS lintLzu Tao-0/+8
2019-12-21Deprecate unused_label lintflip1995-0/+9
This lint was uplifted/turned into warn-by-default in rustc
2019-11-07Auto merge of #4757 - evanjs:issue/4748, r=phanschbors-62/+61
Fix Deprecated lints don't expand ### Move doc comments inside of declare_deprecated_lint macros so that they are picked up by lintlib.py ### fixes #4748 Unable to `cargo test` locally (I'm on NixOS, and keep getting errors that are similar to those #4714 might solve) but I have verified that all deprecated lints can now be expanded like other lints. ![2019-10-30_21:06:28](https://user-images.githubusercontent.com/1847524/67910501-5815de00-fb59-11e9-9fa2-91fe6a8b9bb9.png) changelog: Show deprecated lints in lint documentation again
2019-11-07Deprecate `into_iter_on_array` lintflip1995-0/+9
This lint was uplifted/reimplemented by rustc. Rustup to rust-lang/rust#66017
2019-11-02deprecated_lints: re-fix ASSIGN_OPS lint doc-commentEvan Stoll-5/+5
2019-11-02deprecated_lints: align doc comment indents with `pub LINT_NAME`Evan Stoll-56/+56
2019-11-02deprecated_lints: remove extraneous `declare_deprecated_lint`Evan Stoll-1/+0
2019-10-30Fix #4748 - Deprecated lints don't expandEvan Stoll-13/+13
- Move doc comments inside of declare_deprecated_lint macros so that they are picked up by lintlib.py
2019-08-14Deprecate unused_collect lintPhilipp Hansch-0/+8
I found this because we only had two test cases in total for this lint. It turns out the functionality is fully covered by rustc these days. [Playground Examples](https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=eb8ee6db389c77180c9fb152d3c608f4) changelog: Deprecate `unused_collect` lint. This is fully covered by rustc's `#[must_use]` on `collect` cc #2846
2019-08-12Fix invalid_ref deprecationPhilipp Hansch-1/+1
2019-08-11deprecate invalid_ref lintRalf Jung-0/+9
2019-03-10Various cosmetic improvements.Alexander Regueiro-1/+1
2019-01-08Remove all copyright license headersPhilipp Hansch-10/+0
Discussion previously happened in https://github.com/rust-lang/rust/pull/43498
2018-12-03Remove unsafe_vector_initialization lintDavid Tolnay-0/+11
2018-10-17Rename if_let_redundant_pattern_matching to redundant_pattern_matchingCYBAI-1/+11
Also, making the old one deprecated
2018-10-06Add license header to Rust filesManish Goregaokar-0/+10
2018-08-13deprecate assign_ops lintJonathan Goodman-0/+10
2018-04-11Deprecate misaligned_transmuteDevon Hollowood-0/+11
2017-10-19Deprecate should_assert_eq lintcgm616-0/+8
This should close #2090.
2017-06-18Replace `Range::step_by` checking with `Iterator::step_by`Oliver Schneider-0/+10
2017-01-14deprecate extend_from_slice lintAndre Bogus-0/+11
2016-05-27split clippy into lints, plugin and cargo-clippyOliver Schneider-0/+44