deny-by-default & report in deps uninhabited_static#152853
deny-by-default & report in deps uninhabited_static#152853WaffleLapkin wants to merge 1 commit intorust-lang:mainfrom
uninhabited_static#152853Conversation
|
r? @chenyukang rustbot has assigned @chenyukang. Use Why was this reviewer chosen?The reviewer was selected based on:
|
This comment has been minimized.
This comment has been minimized.
b5caed3 to
8bf6c59
Compare
|
@bors r=chenyukang |
|
seems need the decision from language team. |
|
Since it's still just a lint, I'd be fine to accept this under meeting consensus. (Hopefully we'll discuss it today.) |
|
We talked about this in the meeting today. Makes sense. Let's propose to do it. @rfcbot fcp merge lang |
|
Team member @traviscross has proposed to merge this. The next step is review by the rest of the tagged team members: No concerns currently listed. Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! cc @rust-lang/lang-advisors: FCP proposed for lang, please feel free to register concerns. |
|
🔔 This is now entering its final comment period, as per the review above. 🔔 |
This comment has been minimized.
This comment has been minimized.
|
The final comment period, with a disposition to merge, as per the review above, is now complete. As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed. |
8bf6c59 to
4c83028
Compare
This comment has been minimized.
This comment has been minimized.
|
@rustbot review |
This comment has been minimized.
This comment has been minimized.
4c83028 to
008fda0
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
|
@rustbot reroll |
| /// | ||
| /// ```rust | ||
| /// ```rust,compile_fail | ||
| /// enum Void {} |
There was a problem hiding this comment.
Tests need to pass with both --stage=1 and --stage=2. When switching a lint from warn to deny, this will cause the test to fail with stage 2, but the stage1 tests won't fail. stage1 is tested on CI, so this won't pass without some way to make it fail on both. I would recommend something like:
| /// enum Void {} | |
| /// # #![deny(uninhabited_static)] | |
| /// enum Void {} |
I opened a topic about this at https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/Skipping.20stage.201.20tests/near/583286344.
There was a problem hiding this comment.
This probably needs sth like
#[cfg_attr(bootstrap, doc = "```rust")]
#[cfg_attr(not(bootstrap), doc = "```rust,compile_fail")]EDIT: yes, I can confirm this works as I expected locally (./x test compiler --stage=1 and ./x test compiler --stage=2).
There was a problem hiding this comment.
Thanks. Need to fix a --stage=2 doctest bootstrap/not-bootstrap gating, then r=me and chenyukang.
@rustbot author
View all comments
The lint was introduced as a FCW in #78324 and landed in rust 1.49.0 (5 years ago); see also #74840.
Per the discussion in #149518 (comment).
cc @fmease @scottmcm @traviscross