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

Enable empty_loop lint for no_std crates #6205

Merged
merged 3 commits into from
Nov 8, 2020
Merged

Conversation

josephlr
Copy link
Contributor

@josephlr josephlr commented Oct 23, 2020

Depends on #6162. Fixes #6161

We skip the lint if the loop {} is in the #[panic_handler] as the
main recommendation we give is to panic, which obviously isn't
possible in a panic handler.

changelog: Enable empty_loop lint for no_std crates

@rust-highfive
Copy link

r? @phansch

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

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Oct 23, 2020
@flip1995
Copy link
Member

I think this is a good change. After #6162 is merged, you can rebase this on top of master and ping me to approve it.

r? @flip1995

@rust-highfive rust-highfive assigned flip1995 and unassigned phansch Oct 25, 2020
@bors
Copy link
Contributor

bors commented Oct 25, 2020

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

Note that reviewers usually do not review pull requests until merge conflicts are resolved! Once you resolve the conflicts, you should change the labels applied by bors to indicate that your PR is ready for review. Post this as a comment to change the labels:

@rustbot modify labels: +S-waiting-on-review -S-waiting-on-author

@giraffate
Copy link
Contributor

@rustbot modify labels: +S-waiting-on-author -S-waiting-on-review

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action from the author. (Use `@rustbot ready` to update this status) and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties labels Oct 25, 2020
@josephlr josephlr force-pushed the empty-loop2 branch 2 times, most recently from 38087a8 to c39386a Compare October 26, 2020 10:23
@josephlr
Copy link
Contributor Author

@flip1995 this is now rebased and ready for review.

Copy link
Member

@flip1995 flip1995 left a comment

Choose a reason for hiding this comment

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

Only NITs

clippy_lints/src/loops.rs Outdated Show resolved Hide resolved
@josephlr
Copy link
Contributor Author

josephlr commented Nov 4, 2020

@flip1995 NIT fixed, sorry for the delay, accidentally missed the email for this.

josephlr and others added 3 commits November 8, 2020 12:38
We skip the lint if the `loop {}` is in the `#[panic_handler]` as the
main recommendation we give is to panic, which obviously isn't
possible in a panic handler.

Signed-off-by: Joe Richey <[email protected]>
Fix NITs

Co-authored-by: Philipp Krones <[email protected]>
@flip1995
Copy link
Member

flip1995 commented Nov 8, 2020

@bors r+

Thanks!

@bors
Copy link
Contributor

bors commented Nov 8, 2020

📌 Commit 00dee9d has been approved by flip1995

@bors
Copy link
Contributor

bors commented Nov 8, 2020

⌛ Testing commit 00dee9d with merge abfa331...

@bors
Copy link
Contributor

bors commented Nov 8, 2020

☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test
Approved by: flip1995
Pushing abfa331 to master...

@bors bors merged commit abfa331 into rust-lang:master Nov 8, 2020
@josephlr josephlr deleted the empty-loop2 branch March 1, 2021 05:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-author Status: This is awaiting some action from the author. (Use `@rustbot ready` to update this status)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lint: enable empty_loop for no_std crates
7 participants