Skip to content

Warn if function name default() is used without implementing the Default trait #8550

@kamulos

Description

@kamulos

Description

Just stumbled on this in a code review. Would it make sense to check the naming of a member function? If a default() function is used (especially as a constructor) I would expect, that the Default trait is implemented.

Not sure if this would be it's own lint or integrated in an existing one

Version

No response

Additional Labels

No response

Metadata

Metadata

Assignees

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