d068043891
[`useless_conversion`]: only lint on paths to fn items and fix FP in macro Fixes #11065 (which is actually two issues: an ICE and a false positive) It now makes sure that the function call path points to a function-like item (and not e.g. a `const` like in the linked issue), so that calling `TyCtxt::fn_sig` later in the lint does not ICE (fixes https://github.com/rust-lang/rust-clippy/issues/11065#issuecomment-1616836099). It *also* makes sure that the expression is not part of a macro call (fixes https://github.com/rust-lang/rust-clippy/issues/11065#issuecomment-1616919639). ~~I'm not sure if there's a better way to check this other than to walk the parent expr chain and see if any of them are expansions.~~ (edit: it doesn't do this anymore) changelog: [`useless_conversion`]: fix ICE when call receiver is a non-fn item changelog: [`useless_conversion`]: don't lint if argument is a macro argument (fixes a FP) r? `@llogiq` (reviewed #10814, which introduced these issues) |
||
---|---|---|
.. | ||
auxiliary | ||
third-party | ||
associated-constant-ice.rs | ||
cc_seme.rs | ||
enum-glob-import-crate.rs | ||
ice_exact_size.rs | ||
ice-360.rs | ||
ice-360.stderr | ||
ice-700.rs | ||
ice-1588.rs | ||
ice-1782.rs | ||
ice-1969.rs | ||
ice-2499.rs | ||
ice-2594.rs | ||
ice-2727.rs | ||
ice-2760.rs | ||
ice-2774.rs | ||
ice-2774.stderr | ||
ice-2862.rs | ||
ice-2865.rs | ||
ice-3151.rs | ||
ice-3462.rs | ||
ice-3717.rs | ||
ice-3717.stderr | ||
ice-3741.rs | ||
ice-3747.rs | ||
ice-3891.rs | ||
ice-3891.stderr | ||
ice-3969.rs | ||
ice-3969.stderr | ||
ice-4121.rs | ||
ice-4545.rs | ||
ice-4579.rs | ||
ice-4671.rs | ||
ice-4727.rs | ||
ice-4760.rs | ||
ice-4775.rs | ||
ice-4968.rs | ||
ice-5207.rs | ||
ice-5223.rs | ||
ice-5238.rs | ||
ice-5389.rs | ||
ice-5497.rs | ||
ice-5497.stderr | ||
ice-5579.rs | ||
ice-5835.rs | ||
ice-5835.stderr | ||
ice-5872.rs | ||
ice-5872.stderr | ||
ice-5944.rs | ||
ice-6139.rs | ||
ice-6153.rs | ||
ice-6179.rs | ||
ice-6250.rs | ||
ice-6250.stderr | ||
ice-6251.rs | ||
ice-6251.stderr | ||
ice-6252.rs | ||
ice-6252.stderr | ||
ice-6254.rs | ||
ice-6254.stderr | ||
ice-6255.rs | ||
ice-6255.stderr | ||
ice-6256.rs | ||
ice-6256.stderr | ||
ice-6332.rs | ||
ice-6539.rs | ||
ice-6792.rs | ||
ice-6793.rs | ||
ice-6840.rs | ||
ice-7012.rs | ||
ice-7126.rs | ||
ice-7169.rs | ||
ice-7169.stderr | ||
ice-7231.rs | ||
ice-7272.rs | ||
ice-7340.rs | ||
ice-7410.rs | ||
ice-7423.rs | ||
ice-7868.rs | ||
ice-7868.stderr | ||
ice-7869.rs | ||
ice-7869.stderr | ||
ice-7934.rs | ||
ice-8250.rs | ||
ice-8250.stderr | ||
ice-8386.rs | ||
ice-8681.rs | ||
ice-8821.rs | ||
ice-8821.stderr | ||
ice-8850.rs | ||
ice-8850.stderr | ||
ice-9041.rs | ||
ice-9041.stderr | ||
ice-9238.rs | ||
ice-9242.rs | ||
ice-9405.rs | ||
ice-9405.stderr | ||
ice-9414.rs | ||
ice-9445.rs | ||
ice-9445.stderr | ||
ice-9459.rs | ||
ice-9463.rs | ||
ice-9463.stderr | ||
ice-9625.rs | ||
ice-9746.rs | ||
ice-10148.rs | ||
ice-10148.stderr | ||
ice-10645.rs | ||
ice-10645.stderr | ||
ice-10912.rs | ||
ice-10912.stderr | ||
ice-11065.rs | ||
ice-96721.rs | ||
ice-96721.stderr | ||
ice-rust-107877.rs | ||
if_same_then_else.rs | ||
implements-trait.rs | ||
inherent_impl.rs | ||
issue-825.rs | ||
issues_loop_mut_cond.rs | ||
match_same_arms_const.rs | ||
mut_mut_macro.rs | ||
needless_borrow_fp.rs | ||
needless_lifetimes_impl_trait.rs | ||
needless_lifetimes_impl_trait.stderr | ||
needless_pass_by_value-w-late-bound.rs | ||
needless_pass_by_value-w-late-bound.stderr | ||
regressions.rs | ||
returns.rs | ||
shadow.rs | ||
single-match-else.rs | ||
trivial_bounds.rs | ||
used_underscore_binding_macro.rs |