Skip to content

match_ref_pats should lint against if let (ref x) = *x #5038

Open
@Luro02

Description

@Luro02

This is pointless and has no benefit:

if let ErrorKind::Multiple(ref items) = *self

This is how it should be written

if let ErrorKind::Multiple(items) = &self

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-enhancementCategory: Enhancement of lints, like adding more cases or adding help messagesL-styleLint: Belongs in the style lint group

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions