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

extended [allowRegex] parameter for unused-parameter and unused-receiver rules #858

Merged
merged 3 commits into from
Aug 11, 2023

Conversation

comdiv
Copy link
Contributor

@comdiv comdiv commented Aug 7, 2023

Impl for #613 feature-request

Now can provide custom regexes for unused-parameter and unused-receiver to allow names matching some regex, no just _ itself (does'nt break default behavior)

[rule.unused-parameter]
     Arguments = [ { allowRegex = "^_" } ]

[rule.unused-receiver]
     Arguments = [ { allowRegex = "^_" } ]

@chavacava
Copy link
Collaborator

Hi @comdiv, thanks for the PR. Please open an issue before opening a PR.
Opening an issue will let us discuss on the subject and find the right way to cope with the request.

@comdiv
Copy link
Contributor Author

comdiv commented Aug 8, 2023

Sorry, i thought it was open early - it's fix for old issue #613 - what exatly i have to do?

@chavacava chavacava merged commit b31eb18 into mgechev:master Aug 11, 2023
4 checks passed
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.

2 participants