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

Misc fixes #11186

Closed
wants to merge 2 commits into from
Closed

Misc fixes #11186

wants to merge 2 commits into from

Conversation

Centri3
Copy link
Member

@Centri3 Centri3 commented Jul 19, 2023

Fixes a typo in needless_pass_by_ref_mut's description and changes its msg a bit.
Also, single_call_fn now takes into account lint attrs, which it didn't before

changelog: [single_call_fn]: Now takes into account lint attributes on the function's signature (e.g., #[allow(...)])

@rustbot
Copy link
Collaborator

rustbot commented Jul 19, 2023

r? @dswij

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Jul 19, 2023
@Centri3
Copy link
Member Author

Centri3 commented Jul 19, 2023

Oh right, I cleaned up tests which didn't allow needless_pass_by_ref_mut before

@Centri3 Centri3 force-pushed the misc branch 3 times, most recently from 9906122 to dd50194 Compare July 20, 2023 12:08
@bors
Copy link
Collaborator

bors commented Jul 25, 2023

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

@bors
Copy link
Collaborator

bors commented Jul 25, 2023

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

Comment on lines +77 to +82
#[allow(clippy::single_call_fn)]
fn lint_attr_test() {}

fn lint_attr_test_caller() {
lint_attr_test();
}
Copy link
Member

Choose a reason for hiding this comment

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

What was not working before?

Copy link
Member Author

Choose a reason for hiding this comment

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

Lint attributes, allowing it on the function wouldn't do anything (I think). Similarly with warn and others

|
LL | let _ = future;
| ^^^^^^^^^^^^^^^
|
= help: consider awaiting the future or dropping explicitly with `std::mem::drop`

error: this argument is a mutable reference, but not used mutably
Copy link
Member

Choose a reason for hiding this comment

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

Wonder if we can have a CI test to prevent this stuff from happening 🤔

Copy link
Member Author

Choose a reason for hiding this comment

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

We can probably search for -D followed by anything that isn't a specific lint. Not sure how you'd set that "specific lint" for each test though

@bors
Copy link
Collaborator

bors commented Aug 1, 2023

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

Also moves `tuple_array_conversions` to `pedantic`, because rust-lang#11171 didn't contain it fsr
@bors
Copy link
Collaborator

bors commented Aug 11, 2023

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

Copy link
Member

@dswij dswij left a comment

Choose a reason for hiding this comment

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

@Centri3 Sorry for the long wait. Can you help to resolve the merge conflict here?

@@ -37,7 +37,7 @@ declare_clippy_lint! {
/// ```
#[clippy::version = "1.72.0"]
pub TUPLE_ARRAY_CONVERSIONS,
nursery,
pedantic,
Copy link
Member

Choose a reason for hiding this comment

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

Are we sure we want to move this to pedantic?

@xFrednet
Copy link
Member

Hey this is triage, I'm closing this due to inactivity. Currently, @Centri3 sadly doesn't have the time to continue this implementation. If anyone is interested in continuing this PR, you're more than welcome to create a new PR and push it over the finish line. :D

Thank you to @Centri3 and the reviewers for the time, that you already put into this!

@rustbot label +S-inactive-closed -S-waiting-on-author -S-waiting-on-review

@xFrednet xFrednet closed this Mar 31, 2024
@rustbot rustbot added S-inactive-closed Status: Closed due to inactivity and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties labels Mar 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-inactive-closed Status: Closed due to inactivity
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants