Skip to content

Disable code Action for clippy::needless_return #16542

Closed
@aminya

Description

@aminya

Rust-analyzer has started to give code action suggestions for removing return from my code despite me allowing clippy::needless_return via #![allow(clippy::needless_return)].

In my coding style, I do not like my returns to be implicit, and I don't really align with the push to force not using return statements in the Rust tooling (e.g. Clippy, Rust-analyzer, etc).

Could you add an option to remove this code action, or respect the clippy configuration enabled at the module level?

rust-analyzer version: 0.4.1838-standalone

rustc version: rustc 1.75.0-nightly (42b1224e9 2023-10-15)

relevant settings: (eg. client settings, or environment variables like CARGO, RUSTC, RUSTUP_HOME or CARGO_HOME)

The offending feature:

#16460

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-diagnosticsdiagnostics / error reportingC-bugCategory: bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions