Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unused deplicated #202

Closed
wants to merge 5 commits into from
Closed

Conversation

Hmikihiro
Copy link
Contributor

Issue #, if available:#17

Description of changes:
This PR adds functionality to:

  1. Warn about unused approval patterns in allowed_external_types.
  2. Warn about duplicated approval patterns that match the same type.

For example:

pub use foo::bar;
allowed_external_types = ["foo::*", "foo::bar"]

Here, foo::bar matches both "foo::*" and "foo::bar". However, only "foo::*" is necessary. With this PR, a warning is issued when multiple patterns match the same type. This helps in reducing redundant definitions in configuration.

Additionally, a warning is also issued for patterns in allowed_external_types that do not match any type in the public API.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Signed-off-by: Hayashi Mikihiro <[email protected]>
Signed-off-by: Hayashi Mikihiro <[email protected]>
@Hmikihiro Hmikihiro requested a review from a team as a code owner December 25, 2024 02:17
@Hmikihiro Hmikihiro closed this Dec 25, 2024
@Hmikihiro Hmikihiro deleted the unused_deplicated branch December 25, 2024 02:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant