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

Allow giving reasons for disallowed_methods #7621

Merged
merged 1 commit into from
Sep 9, 2021
Merged

Allow giving reasons for disallowed_methods #7621

merged 1 commit into from
Sep 9, 2021

Conversation

azdavis
Copy link
Contributor

@azdavis azdavis commented Sep 1, 2021

Fixes #7609.

This permits writing the config for disallowed-methods as either a list of strings (like before) or a list of tables, where each table gives the path to the disallowed method and an optional reason for why the method is disallowed.

changelog: Allow giving reasons for [disallowed_methods]

@rust-highfive
Copy link

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @camsteffen (or someone else) soon.

Please see the contribution instructions for more information.

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Sep 1, 2021
@azdavis azdavis changed the title Allow giving reasons for [disallowed_methods] Allow giving reasons for disallowed_methods Sep 1, 2021
clippy_lints/src/disallowed_method.rs Outdated Show resolved Hide resolved
clippy_lints/src/disallowed_method.rs Outdated Show resolved Hide resolved
@bors
Copy link
Collaborator

bors commented Sep 2, 2021

☔ The latest upstream changes (presumably #7604) made this pull request unmergeable. Please resolve the merge conflicts.

@azdavis
Copy link
Contributor Author

azdavis commented Sep 2, 2021

rebased and force-pushed to address feedback

Copy link
Contributor

@camsteffen camsteffen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is nice! Just a few nits.

clippy_lints/src/disallowed_method.rs Outdated Show resolved Hide resolved
clippy_lints/src/disallowed_method.rs Outdated Show resolved Hide resolved
clippy_lints/src/disallowed_method.rs Outdated Show resolved Hide resolved
clippy_lints/src/disallowed_method.rs Outdated Show resolved Hide resolved
clippy_lints/src/disallowed_method.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@camsteffen camsteffen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Please squash commits.

@azdavis
Copy link
Contributor Author

azdavis commented Sep 9, 2021

ok, rebased and squashed into 1 commit

@camsteffen
Copy link
Contributor

Thanks and nice first contribution!

@bors r+

@bors
Copy link
Collaborator

bors commented Sep 9, 2021

📌 Commit 293db0d has been approved by camsteffen

@bors
Copy link
Collaborator

bors commented Sep 9, 2021

⌛ Testing commit 293db0d with merge 36e6469...

@bors
Copy link
Collaborator

bors commented Sep 9, 2021

☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test
Approved by: camsteffen
Pushing 36e6469 to master...

@bors bors merged commit 36e6469 into rust-lang:master Sep 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties
Projects
None yet
Development

Successfully merging this pull request may close these issues.

disallowed_methods should allow for reasons in the toml file
5 participants