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

Paper over an accidental regression #115844

Merged
merged 1 commit into from
Sep 14, 2023

Conversation

oli-obk
Copy link
Contributor

@oli-obk oli-obk commented Sep 14, 2023

r? types

cc #115781 (do not close issue until beta backport has been performed)

The PR reasons are explained with comments in the source.

In order to keep the diff simple, this PR effectively reverts #113661, but only for RPITs. I will submit a follow up PR that fixes this correctly instead of just disabling the newly added check for RPITs. This PR should be significantly easier to review for beta backport

@oli-obk oli-obk added the beta-nominated Nominated for backporting to the compiler in the beta channel. label Sep 14, 2023
@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 14, 2023
@@ -8,7 +8,7 @@ fn without_lt() -> impl for<'a> Trait<'a, Assoc = WithoutLt> {}
//~^ ERROR captures lifetime that does not appear in bounds

type WithLt<'a> = impl Sized + 'a;
//~^ ERROR concrete type differs from previous defining opaque type use

Copy link
Member

Choose a reason for hiding this comment

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

Why does this disappear? It's a TAIT, not RPIT?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it's used in an RPIT right below

@@ -461,7 +461,15 @@ fn check_opaque_meets_bounds<'tcx>(
}
match origin {
// Checked when type checking the function containing them.
hir::OpaqueTyOrigin::FnReturn(..) | hir::OpaqueTyOrigin::AsyncFn(..) => {}
hir::OpaqueTyOrigin::FnReturn(..) | hir::OpaqueTyOrigin::AsyncFn(..) => {
Copy link
Member

Choose a reason for hiding this comment

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

Wondering if AsyncFn should continue to fall through?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

hmm true. But this is a revert of any stable effects of my old PR, there may be a repro with async fn

Copy link
Member

Choose a reason for hiding this comment

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

Ah yeah, my mind jumped directly to AFITs, not even thinking about standalone functions.

@jackh726
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Sep 14, 2023

📌 Commit 0277184 has been approved by jackh726

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 14, 2023
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 14, 2023
…iaskrgr

Rollup of 4 pull requests

Successful merges:

 - rust-lang#115772 (Improve Span in smir)
 - rust-lang#115832 (Fix the error message for `#![feature(no_coverage)]`)
 - rust-lang#115834 (Properly consider binder vars in `HasTypeFlagsVisitor`)
 - rust-lang#115844 (Paper over an accidental regression)

r? `@ghost`
`@rustbot` modify labels: rollup
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Sep 14, 2023
Rollup merge of rust-lang#115844 - oli-obk:opaque_lifetime_ambiguity, r=jackh726

Paper over an accidental regression

r? types

cc rust-lang#115781 (do not close issue until beta backport has been performed)

The PR reasons are explained with comments in the source.

In order to keep the diff simple, this PR effectively reverts rust-lang#113661, but only for RPITs. I will submit a follow up PR that fixes this correctly instead of just disabling the newly added check for RPITs. This PR should be significantly easier to review for beta backport
@bors bors merged commit 9362604 into rust-lang:master Sep 14, 2023
11 checks passed
@rustbot rustbot added this to the 1.74.0 milestone Sep 14, 2023
@bors
Copy link
Contributor

bors commented Sep 14, 2023

⌛ Testing commit 0277184 with merge ccf817b...

@oli-obk oli-obk deleted the opaque_lifetime_ambiguity branch September 18, 2023 07:39
@apiraino
Copy link
Contributor

Beta backport accepted as per compiler team on Zulip

@rustbot label +beta-accepted

@rustbot rustbot added the beta-accepted Accepted for backporting to the compiler in the beta channel. label Sep 21, 2023
@cuviper cuviper mentioned this pull request Sep 22, 2023
@cuviper cuviper modified the milestones: 1.74.0, 1.73.0 Sep 22, 2023
@cuviper cuviper removed the beta-nominated Nominated for backporting to the compiler in the beta channel. label Sep 22, 2023
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 22, 2023
[beta] backports

-  Fix a pthread_t handle leak rust-lang#114696
-  MCP661: Move wasm32-wasi-preview1-threads target to Tier 2 rust-lang#115345
-  Don't modify libstd to dump rustc ICEs rust-lang#115627
-  Paper over an accidental regression rust-lang#115844
-  Update to LLVM 17.0.0 rust-lang#115959

r? cuviper
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beta-accepted Accepted for backporting to the compiler in the beta channel. 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.

7 participants