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

Fix lint levels not getting overridden by attrs on Stmt nodes #130293

Merged
merged 1 commit into from
Sep 15, 2024

Conversation

gurry
Copy link
Contributor

@gurry gurry commented Sep 13, 2024

Fixes #130142. See comments on the issue for context.

r? @cjgillot

@gurry
Copy link
Contributor Author

gurry commented Sep 13, 2024

@cjgillot Looks like just visiting the Stmt and adding the level on it is not enough as it results in unfulfilled expectation warnings as seen in the new test I have added as well as in some of the pre-existing tests. I think we'll have to ensure we add the level on only one of the nodes (preferably the parent) when they occur on the same HIR hierarchy.

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Sep 13, 2024
@cjgillot
Copy link
Contributor

Do you mind rebasing on master? #130050 should have fixed that issue.

@gurry gurry force-pushed the 130142-lint-level-issue branch from bea0e64 to 51b3b20 Compare September 14, 2024 02:59
@rust-log-analyzer

This comment has been minimized.

@gurry gurry force-pushed the 130142-lint-level-issue branch from 51b3b20 to fd3ee92 Compare September 14, 2024 10:42
@gurry gurry marked this pull request as ready for review September 14, 2024 12:32
@rustbot
Copy link
Collaborator

rustbot commented Sep 14, 2024

Some changes occurred in src/tools/clippy

cc @rust-lang/clippy

@gurry
Copy link
Contributor Author

gurry commented Sep 14, 2024

Do you mind rebasing on master? #130050 should have fixed that issue.

Rebasing worked. Thanks :). Please review

@cjgillot
Copy link
Contributor

@bors r+

@bors
Copy link
Contributor

bors commented Sep 15, 2024

📌 Commit fd3ee92 has been approved by cjgillot

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Sep 15, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 15, 2024
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#129439 (Implement feature `string_from_utf8_lossy_owned` for lossy conversion from `Vec<u8>` to `String` methods)
 - rust-lang#129828 (miri: treat non-memory local variables properly for data race detection)
 - rust-lang#130110 (make dist vendoring configurable)
 - rust-lang#130293 (Fix lint levels not getting overridden by attrs on `Stmt` nodes)
 - rust-lang#130342 (interpret, miri: fix dealing with overflow during slice indexing and allocation)

Failed merges:

 - rust-lang#130394 (const: don't ICE when encountering a mutable ref to immutable memory)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 18a93ca into rust-lang:master Sep 15, 2024
6 checks passed
@rustbot rustbot added this to the 1.83.0 milestone Sep 15, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Sep 15, 2024
Rollup merge of rust-lang#130293 - gurry:130142-lint-level-issue, r=cjgillot

Fix lint levels not getting overridden by attrs on `Stmt` nodes

Fixes rust-lang#130142. See comments on the issue for context.

r? `@cjgillot`
@gurry gurry deleted the 130142-lint-level-issue branch September 16, 2024 00:45
bors pushed a commit to rust-lang-ci/rust that referenced this pull request Sep 24, 2024
…jgillot

Fix lint levels not getting overridden by attrs on `Stmt` nodes

Fixes rust-lang#130142. See comments on the issue for context.

r? `@cjgillot`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

#[expect(unused_must_use)] does not work when applied directly to statement
5 participants