Skip to content

Unused traits are not beign reported #158

@klapuch

Description

@klapuch

Hello,

Thank you for providing a great set of rules! We've encountered an unexpected behavior, and I'd like to discuss whether this is intentional or if there's something we can do about it.

The issue relates to traits. When we use a trait from a third-party package (a "vendor" package) without actually using any of its methods, no error is raised—regardless of method visibility. However, when we use our own traits within the project, unused methods are correctly reported. I would expect the same behavior for vendor traits as our project traits.

To illustrate this, I've prepared a minimal demo: https://github.com/klapuch/DeadCodeTest

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions