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

[stable] Backport Clippy ICE fix to stable #77750

Closed
wants to merge 57 commits into from

Conversation

flip1995
Copy link
Member

@flip1995 flip1995 commented Oct 9, 2020

This ICE slipped through. There were multiple issues opened after the 1.47 release about this ICE:

rust-lang/rust-clippy#6140
rust-lang/rust-clippy#6143
rust-lang/rust-clippy#6147

This PR backports the fix for this ICE: rust-lang/rust-clippy#5948

This probably does not warrant a point release, but it would be great to include this, if there is one.

pietroalbini and others added 30 commits August 25, 2020 23:04
…crum

[beta] Prepare beta 1.47.0

Also backported the release notes change.

r? @Mark-Simulacrum
This fixes a regression introduced in
rust-lang#74855.
[beta] Backport fix for swapped stability attributes

This backports the only commit in rust-lang#75953, fixing one unstable lint which ran on stable and one stable lint which only ran on nightly. This change can be replicated with
```
git fetch origin
git checkout origin/beta
git cherry-pick 29399fa
```
…acrum

[beta] Update cargo

1 commits in 51b66125ba97d2906f461b3f4e0408f206299bb6..f3c7e066ad66e05439cf8eab165a2de580b41aaf
2020-08-19 20:22:52 +0000 to 2020-08-28 19:37:58 +0000
- [beta] Fix LTO with doctests. (rust-lang/cargo#8658)
It emits a lint when the pushed item is a literal, a constant and an immutable binding that are initialized with those.
Add tests in which the variable is initialized with a match expression and function call
These tests will fall without the next commit.
Apply suggestions from code review

Co-authored-by: Joshua Nelson <[email protected]>
CDB doesn't care that you're using static_cast between unrelated types.
VS(C) does.  These should've been reinterpret_cast or C casts.
Cast is from e.g. `u8*` to `tuple<$T1, $T2>*`
Issue rust-lang#74616 tracks a backwards-compatibility hack for certain macros.
This has is implemented by hard-coding the filenames and macro names of
certain code that we want to continue to compile.

However, the initial implementation of the hack was based on the
directory structure when building the crate from its repository (e.g.
`js-sys/src/lib.rs`). When the crate is build as a dependency, it will
include a version number from the clone from the cargo registry (e.g.
`js-sys-0.3.17/src/lib.rs`), which would fail the check.

This commit modifies the backwards-compatibility hack to check that
desired crate name (`js-sys` or `time-macros-impl`) is a prefix of the
proper part of the path.

See rust-lang#76070 (comment)
for more details.
…ulacrum

[beta] backports

* Ignore rustc_private items from std docs rust-lang#76571
* Fix HashMap visualizers in Visual Studio (Code) rust-lang#76389
* Account for version number in NtIdent hack rust-lang#76331
* Account for async functions when suggesting new named lifetime rust-lang#75867
* Fix loading pretty-printers in rust-lldb script rust-lang#76015

This also bumps to the released stable compiler.
The logic is currently broken and we need to disable it to fix a beta
regression (see rust-lang#76803)
…ulacrum

[beta] backports

This backports the following:
 *  revert const_type_id stabilization rust-lang#77083
 * [mir-opt] Disable the `ConsideredEqual` logic in SimplifyBranchSame opt rust-lang#76837
 * Rename Iterator::get_unchecked rust-lang#77201 (manually, because of file renaming and other issues on master causing literal cherry-pick to fail)
 *  Rebase LLVM onto 11.0.0-rc3 rust-lang#77063 (bumping direct to master, see rust-lang#77063 (comment)).

The last two have not yet been approved by compiler team, but I'm posting this now and going to go ahead and approve as I expect both to get approved and we want testing as much as possible before release in ~2 weeks.

r? `@ghost`
[beta][clippy] backport multiple FP fixes for a warn-by-default lint

This backports the PR rust-lang/rust-clippy#6016 fixing multiple FPs:

rust-lang/rust-clippy#5902
rust-lang/rust-clippy#5979
rust-lang/rust-clippy#5985

We didn't have any complaints about this lint, since me merged this PR.

cc `@ebroto` (sorry I forgot about this, since we talked about the backport 3 weeks ago 😐)

r? `@pietroalbini`
pietroalbini and others added 4 commits October 7, 2020 09:44
Rust 1.47.0 stable release, take 2

This PR adds a workaround for rust-lang#76980 to the existing stable 1.47.0 branch. I will invalidate the dev artifacts and issue another pre-release once the PR is merged, to let people test this change.

r? `@ghost`
@rust-highfive
Copy link
Collaborator

r? @Mark-Simulacrum

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

@rust-highfive
Copy link
Collaborator

⚠️ Warning ⚠️

  • Pull requests are usually filed against the master branch for this repo, but this one is against stable. Please double check that you specified the right target!

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

flip1995 commented Oct 9, 2020

@rustbot modify labels: +stable-nominated

@rustbot rustbot added the stable-nominated Nominated for backporting to the compiler in the stable channel. label Oct 9, 2020
@flip1995 flip1995 changed the title Backport Clippy ICE fix to stable [stable] Backport Clippy ICE fix to stable Oct 9, 2020
@Mark-Simulacrum
Copy link
Member

We discussed this in the release team meeting last week, and roughly decided that we'd be on board with a backport here presuming we end up doing a point release. There are no current plans for a point release, though.

@Mark-Simulacrum Mark-Simulacrum added the stable-accepted Accepted for backporting to the compiler in the stable channel. label Oct 13, 2020
@Mark-Simulacrum
Copy link
Member

@flip1995 Can you confirm that 1.48 does not contain this regression? Do we have a separate PR with a backport there?

@Mark-Simulacrum Mark-Simulacrum added S-waiting-on-team Status: Awaiting decision from the relevant subteam (see the T-<team> label). and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 13, 2020
@flip1995
Copy link
Member Author

@flip1995 Can you confirm that 1.48 does not contain this regression? Do we have a separate PR with a backport there?

The original commit fixing this (8776db9) was merged with this Clippy sync: #76034

This was 2 days after the 1.46 release. So shortly after 1.47 beta was branched. So it would only be available in 1.48 (current beta).

$ git branch master beta stable --contains=8776db9
  beta
* master

@Mark-Simulacrum
Copy link
Member

Ok, great, thanks.

@crlf0710 crlf0710 added T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue. T-release Relevant to the release subteam, which will review and decide on the PR/issue. labels Oct 30, 2020
@bors
Copy link
Contributor

bors commented Nov 16, 2020

☔ The latest upstream changes (presumably #79075) 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

@flip1995
Copy link
Member Author

This fix will hit stable 1.48 on Thursday, therefore, I will close this.

@flip1995 flip1995 closed this Nov 16, 2020
@flip1995 flip1995 deleted the clippy_stable_backport branch November 16, 2020 09:18
@Mark-Simulacrum Mark-Simulacrum removed stable-accepted Accepted for backporting to the compiler in the stable channel. stable-nominated Nominated for backporting to the compiler in the stable channel. labels Nov 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-team Status: Awaiting decision from the relevant subteam (see the T-<team> label). T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue. T-release Relevant to the release subteam, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.