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

Fix ICE when ADT tail has type error #124057

Merged
merged 1 commit into from
Apr 23, 2024

Conversation

gurry
Copy link
Contributor

@gurry gurry commented Apr 17, 2024

Fixes #124031

@rustbot
Copy link
Collaborator

rustbot commented Apr 17, 2024

r? @compiler-errors

rustbot has assigned @compiler-errors.
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 Apr 17, 2024
Copy link
Member

@compiler-errors compiler-errors left a comment

Choose a reason for hiding this comment

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

I don't like putting this fix here. It feels redundant -- recomputing the tail just to check if it has errors. Can you integrate it into one of the branches below?

Also, why did you choose to handle it here rather than just handle it in the size skeleton code where the ICE actually occurs?

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 17, 2024
@gurry gurry force-pushed the 124031-ice-layout-errored branch 2 times, most recently from bdfddb3 to f83793c Compare April 18, 2024 04:45
@gurry
Copy link
Contributor Author

gurry commented Apr 18, 2024

I don't like putting this fix here. It feels redundant -- recomputing the tail just to check if it has errors. Can you integrate it into one of the branches below?

Also, why did you choose to handle it here rather than just handle it in the size skeleton code where the ICE actually occurs?

Yes, it's better to put it in the size skeleton location. I've moved it there now.

@gurry
Copy link
Contributor Author

gurry commented Apr 21, 2024

@rustbot label -S-waiting-on-author +S-waiting-on-review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Apr 21, 2024
@compiler-errors
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Apr 21, 2024

📌 Commit f83793c 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 Apr 21, 2024
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Apr 21, 2024
…=compiler-errors

Fix ICE when ADT tail has type error

Fixes rust-lang#124031
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Apr 21, 2024
…=compiler-errors

Fix ICE when ADT tail has type error

Fixes rust-lang#124031
@matthiaskrgr
Copy link
Member

this probably needs rebase and fixes another ICE

@matthiaskrgr
Copy link
Member

@bors r-

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Apr 21, 2024
@gurry gurry force-pushed the 124031-ice-layout-errored branch from f83793c to 7e20f0f Compare April 22, 2024 03:32
@gurry
Copy link
Contributor Author

gurry commented Apr 22, 2024

this probably needs rebase and fixes another ICE

Rebased and removed the crash test tests/crashes/124031.rs

@gurry gurry force-pushed the 124031-ice-layout-errored branch from 7e20f0f to 06cd79b Compare April 22, 2024 03:42
@gurry
Copy link
Contributor Author

gurry commented Apr 22, 2024

@rustbot label -S-waiting-on-author +S-waiting-on-review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Apr 22, 2024
@compiler-errors
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Apr 22, 2024

📌 Commit 06cd79b 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 Apr 22, 2024
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Apr 22, 2024
…=compiler-errors

Fix ICE when ADT tail has type error

Fixes rust-lang#124031
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 22, 2024
…llaumeGomez

Rollup of 5 pull requests

Successful merges:

 - rust-lang#104087 (Stabilise inline_const)
 - rust-lang#123792 (Require explicitly marking closures as coroutines)
 - rust-lang#124057 (Fix ICE when ADT tail has type error)
 - rust-lang#124178 ([cleanup] [llvm backend] Prevent creating the same `Instance::mono` multiple times)
 - rust-lang#124220 (Miri: detect wrong vtables in wide pointers)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 23, 2024
…iaskrgr

Rollup of 7 pull requests

Successful merges:

 - rust-lang#123680 (Deny gen keyword in `edition_2024_compat` lints)
 - rust-lang#124057 (Fix ICE when ADT tail has type error)
 - rust-lang#124168 (Use `DefiningOpaqueTypes::Yes` in rustdoc, where the `InferCtxt` is guaranteed to have no opaque types it can define)
 - rust-lang#124197 (Move duplicated code in functions in `tests/rustdoc-gui/notable-trait.goml`)
 - rust-lang#124200 (Improve handling of expr->field errors)
 - rust-lang#124220 (Miri: detect wrong vtables in wide pointers)
 - rust-lang#124266 (remove an unused type from the reentrant lock tests)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 8859631 into rust-lang:master Apr 23, 2024
12 checks passed
@rustbot rustbot added this to the 1.79.0 milestone Apr 23, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Apr 23, 2024
Rollup merge of rust-lang#124057 - gurry:124031-ice-layout-errored, r=compiler-errors

Fix ICE when ADT tail has type error

Fixes rust-lang#124031
@gurry gurry deleted the 124031-ice-layout-errored branch April 30, 2024 10:31
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.

ICE: layout errored yet tail '{type error}' is not a type parameter or a projection
5 participants