Skip to content

new_without_default_derive help is confusing #1579

Closed
@wfraser

Description

@wfraser

The current help text implies it's only for trivial cases that can be solved by typing #[derive(Default)], but the lint really fires for any struct that has a pub fn new() -> Self, even ones that have logic inside them (which can't be replaced with a #[derive(Default)]).

Help text should indicate that it means either doing the derive, or implementing Default by hand.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions