-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
with_negative_coherence
fails to prevent coherence_leak_check
overlap error
#117986
Labels
A-coherence
Area: Coherence
C-bug
Category: This is a bug.
F-negative_impls
#![feature(negative_impls)]
requires-nightly
This issue requires a nightly compiler in some way.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Comments
rustbot
added
needs-triage
This issue may need triage. Remove it if it has been sufficiently triaged.
A-coherence
Area: Coherence
F-negative_impls
#![feature(negative_impls)]
requires-nightly
This issue requires a nightly compiler in some way.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
labels
Nov 16, 2023
👀 I'll look into it |
compiler-errors
removed
the
needs-triage
This issue may need triage. Remove it if it has been sufficiently triaged.
label
Nov 16, 2023
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this issue
Nov 17, 2023
…-in-coherence, r=lcnr Ignore but do not assume region obligations from unifying headers in negative coherence Partly addresses a FIXME that was added in rust-lang#112875. Just as we can throw away the nested trait/projection obligations from unifying two impl headers, we can also just throw away the region obligations too. I removed part of the FIXME that was incorrect, namely: > Given that the only region constraints we get are involving inference regions in the root, it shouldn't matter, but still sus. This is not true when unifying `fn(A)` and `for<'b> fn(&'b B)` which ends up with placeholder region outlives from non-root universes. I'm pretty sure this is okay, though it would be nice if we were to use them as assumptions. See the `explicit` revision of the test I committed, which still fails. Fixes rust-lang#117986 r? lcnr, feel free to reassign tho.
TaKO8Ki
added a commit
to TaKO8Ki/rust
that referenced
this issue
Nov 18, 2023
…-in-coherence, r=lcnr Ignore but do not assume region obligations from unifying headers in negative coherence Partly addresses a FIXME that was added in rust-lang#112875. Just as we can throw away the nested trait/projection obligations from unifying two impl headers, we can also just throw away the region obligations too. I removed part of the FIXME that was incorrect, namely: > Given that the only region constraints we get are involving inference regions in the root, it shouldn't matter, but still sus. This is not true when unifying `fn(A)` and `for<'b> fn(&'b B)` which ends up with placeholder region outlives from non-root universes. I'm pretty sure this is okay, though it would be nice if we were to use them as assumptions. See the `explicit` revision of the test I committed, which still fails. Fixes rust-lang#117986 r? lcnr, feel free to reassign tho.
compiler-errors
added a commit
to compiler-errors/rust
that referenced
this issue
Nov 18, 2023
…-in-coherence, r=lcnr Ignore but do not assume region obligations from unifying headers in negative coherence Partly addresses a FIXME that was added in rust-lang#112875. Just as we can throw away the nested trait/projection obligations from unifying two impl headers, we can also just throw away the region obligations too. I removed part of the FIXME that was incorrect, namely: > Given that the only region constraints we get are involving inference regions in the root, it shouldn't matter, but still sus. This is not true when unifying `fn(A)` and `for<'b> fn(&'b B)` which ends up with placeholder region outlives from non-root universes. I'm pretty sure this is okay, though it would be nice if we were to use them as assumptions. See the `explicit` revision of the test I committed, which still fails. Fixes rust-lang#117986 r? lcnr, feel free to reassign tho.
compiler-errors
added a commit
to compiler-errors/rust
that referenced
this issue
Nov 20, 2023
…-in-coherence, r=lcnr Ignore but do not assume region obligations from unifying headers in negative coherence Partly addresses a FIXME that was added in rust-lang#112875. Just as we can throw away the nested trait/projection obligations from unifying two impl headers, we can also just throw away the region obligations too. I removed part of the FIXME that was incorrect, namely: > Given that the only region constraints we get are involving inference regions in the root, it shouldn't matter, but still sus. This is not true when unifying `fn(A)` and `for<'b> fn(&'b B)` which ends up with placeholder region outlives from non-root universes. I'm pretty sure this is okay, though it would be nice if we were to use them as assumptions. See the `explicit` revision of the test I committed, which still fails. Fixes rust-lang#117986 r? lcnr, feel free to reassign tho.
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this issue
Nov 20, 2023
Rollup merge of rust-lang#117994 - compiler-errors:throw-away-regions-in-coherence, r=lcnr Ignore but do not assume region obligations from unifying headers in negative coherence Partly addresses a FIXME that was added in rust-lang#112875. Just as we can throw away the nested trait/projection obligations from unifying two impl headers, we can also just throw away the region obligations too. I removed part of the FIXME that was incorrect, namely: > Given that the only region constraints we get are involving inference regions in the root, it shouldn't matter, but still sus. This is not true when unifying `fn(A)` and `for<'b> fn(&'b B)` which ends up with placeholder region outlives from non-root universes. I'm pretty sure this is okay, though it would be nice if we were to use them as assumptions. See the `explicit` revision of the test I committed, which still fails. Fixes rust-lang#117986 r? lcnr, feel free to reassign tho.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-coherence
Area: Coherence
C-bug
Category: This is a bug.
F-negative_impls
#![feature(negative_impls)]
requires-nightly
This issue requires a nightly compiler in some way.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
I tried this code:
I expected to see this happen: Compiles successfully
Instead, this happened:
Meta
rustc --version
:@rustbot label A-coherence F-negative_impls requires-nightly T-compiler
The text was updated successfully, but these errors were encountered: