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

Add regression test for #129541 #129542

Merged
merged 1 commit into from
Sep 20, 2024
Merged

Add regression test for #129541 #129542

merged 1 commit into from
Sep 20, 2024

Conversation

zachs18
Copy link
Contributor

@zachs18 zachs18 commented Aug 25, 2024

(maybe?) closes #129541 by adding a test that the code in question continues to compile.

@rustbot
Copy link
Collaborator

rustbot commented Aug 25, 2024

r? @fee1-dead

rustbot has assigned @fee1-dead.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@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 Aug 25, 2024
@fee1-dead
Copy link
Member

I'm putting my review on hold because I'm unsure about the implications of this. This is a concrete example of something that went legal after #122493 landed, when the PR itself did not anticipate allowing more code to compile ("This should not make more or less code compile"). The code snippet here looks fine and sound to me; but I'm not sure if there would be some cursed code that would be unsound and then allowed by the PR.

cc @lukas-code @rust-lang/types

@compiler-errors
Copy link
Member

compiler-errors commented Aug 25, 2024

I'll take a look at this, or if I forget, then lcnr can. As I noted in #129541, I'd like to know precisely why #122493 caused this to compile, although I generally don't believe this to be a regression per se.

@compiler-errors
Copy link
Member

r=me when the fcp is done in the linked issue

Copy link
Member

@lukas-code lukas-code left a comment

Choose a reason for hiding this comment

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

Please also add the test from #129541 (comment) (or a minimized version):

#[derive(Clone)]
struct Hello {
    a: <[Hello] as ToOwned>::Owned,
}

so that we actually test that this is allowed because Sized is coinductive and not just because we skip the Sized check for enums now.

@compiler-errors
Copy link
Member

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Sep 20, 2024

📌 Commit 5f72f9d has been approved by compiler-errors

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

Rollup of 6 pull requests

Successful merges:

 - rust-lang#129542 (Add regression test for rust-lang#129541)
 - rust-lang#129755 (test: cross-edition metavar fragment specifiers)
 - rust-lang#130566 (Break up compiletest `runtest.rs` into smaller helper modules)
 - rust-lang#130585 (Add tidy check for rustdoc templates to ensure the whitespace characters are all stripped)
 - rust-lang#130605 (Fix feature name in test)
 - rust-lang#130607 ([Clippy] Remove final std paths for diagnostic item)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 5c60185 into rust-lang:master Sep 20, 2024
6 checks passed
@rustbot rustbot added this to the 1.83.0 milestone Sep 20, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Sep 20, 2024
Rollup merge of rust-lang#129542 - zachs18:cow-self-test, r=compiler-errors

Add regression test for rust-lang#129541

(maybe?) closes rust-lang#129541 by adding a test that the code in question continues to compile.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.

(Anti-)regression between Rust 1.78.0 and Rust 1.79.0 with struct containing Cow<[Self]>
7 participants