Skip to content

Suggest Entry::or_default for Entry::or_insert_with(Default::default) #3812

Closed
@Arnavion

Description

@Arnavion

For code that calls .or_insert_with(Default::default) on a std::collections::btree_map::Entry or std::collections::hash_map::Entry, clippy should suggest std::collections::btree_map::Entry::or_default and std::collections::hash_map::Entry::or_default

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-lintArea: New lintsL-complexityLint: Belongs in the complexity lint groupgood first issueThese issues are a good way to get started with Clippy

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions