Skip to content

Graduate manual_string_new to clippy::style #10284

Open
@tristan-f-r

Description

@tristan-f-r

manual_string_new is a rule that standardizes how empty strings are created, which is not only a good style option (with no known false-positives in the docs), but also helps prevent against zero-width characters being submitted internally.

The Pull Request (#9366) that moved this to pedantic referred to it as:

  • a fairly minor style change
  • could be very noisy

However, not only are many existing non-pedantic style lints noisy (as they can appear a lot), but this one is also idiomatic and uses an in-built method to create an empty string.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-categoryArea: Categorization of lints

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions