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 unwrap on None #114461

Merged
merged 1 commit into from
Aug 4, 2023
Merged

Fix unwrap on None #114461

merged 1 commit into from
Aug 4, 2023

Conversation

sebastiantoh
Copy link
Contributor

Fixes #114423

r? @estebank

@rustbot
Copy link
Collaborator

rustbot commented Aug 4, 2023

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @estebank (or someone else) soon.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

@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 4, 2023
@estebank
Copy link
Contributor

estebank commented Aug 4, 2023

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Aug 4, 2023

📌 Commit 97aa4ba has been approved by estebank

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 Aug 4, 2023
@@ -0,0 +1,15 @@
struct RGB {
Copy link
Contributor

Choose a reason for hiding this comment

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

Just realized the file name. We're moving away from having no context beyond the issue number in test names. Would you mind changing it to something like issue-114423-ice-regression-in-suggestion.rs?

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Aug 4, 2023
@compiler-errors
Copy link
Member

This PR could've also used a better title -- perhaps something like "Don't unwrap when match tuple index against tuple initializer in suggestion" or something, idk

@tamird
Copy link
Contributor

tamird commented Aug 4, 2023

This is still in the rollup - should it be pulled out until the comments are addressed?

@compiler-errors
Copy link
Member

No, that can be done as a follow-up. The PR name is just for future reference.

bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 4, 2023
…iaskrgr

Rollup of 9 pull requests

Successful merges:

 - rust-lang#113945 (Fix wrong span for trait selection failure error reporting)
 - rust-lang#114351 ([rustc_span][perf] Remove unnecessary string joins and allocs.)
 - rust-lang#114418 (bump parking_lot to 0.12)
 - rust-lang#114434 (Improve spans for indexing expressions)
 - rust-lang#114450 (Fix ICE failed to get layout for ReferencesError)
 - rust-lang#114461 (Fix unwrap on None)
 - rust-lang#114462 (interpret: add mplace_to_ref helper method)
 - rust-lang#114472 (Reword `confusable_idents` lint)
 - rust-lang#114477 (Account for `Rc` and `Arc` when suggesting to clone)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit b7bfffd into rust-lang:master Aug 4, 2023
@rustbot rustbot added this to the 1.73.0 milestone Aug 4, 2023
@sebastiantoh
Copy link
Contributor Author

@estebank thanks for the review! I've created a follow-up PR to address your comment

@compiler-errors thanks for the feedback as well! Will provide a more descriptive title in future

compiler-errors added a commit to compiler-errors/rust that referenced this pull request Aug 5, 2023
…114423-test-names, r=compiler-errors

Rename issue rust-lang#114423 test files to include context

Addresses feedback given in rust-lang#114461 (comment)

r? `@estebank`
@sebastiantoh sebastiantoh deleted the issue-114423 branch August 5, 2023 05:45
flip1995 pushed a commit to flip1995/rust that referenced this pull request Aug 11, 2023
…iaskrgr

Rollup of 9 pull requests

Successful merges:

 - rust-lang#113945 (Fix wrong span for trait selection failure error reporting)
 - rust-lang#114351 ([rustc_span][perf] Remove unnecessary string joins and allocs.)
 - rust-lang#114418 (bump parking_lot to 0.12)
 - rust-lang#114434 (Improve spans for indexing expressions)
 - rust-lang#114450 (Fix ICE failed to get layout for ReferencesError)
 - rust-lang#114461 (Fix unwrap on None)
 - rust-lang#114462 (interpret: add mplace_to_ref helper method)
 - rust-lang#114472 (Reword `confusable_idents` lint)
 - rust-lang#114477 (Account for `Rc` and `Arc` when suggesting to clone)

r? `@ghost`
`@rustbot` modify labels: rollup
calebcartwright pushed a commit to calebcartwright/rust that referenced this pull request Oct 23, 2023
…iaskrgr

Rollup of 9 pull requests

Successful merges:

 - rust-lang#113945 (Fix wrong span for trait selection failure error reporting)
 - rust-lang#114351 ([rustc_span][perf] Remove unnecessary string joins and allocs.)
 - rust-lang#114418 (bump parking_lot to 0.12)
 - rust-lang#114434 (Improve spans for indexing expressions)
 - rust-lang#114450 (Fix ICE failed to get layout for ReferencesError)
 - rust-lang#114461 (Fix unwrap on None)
 - rust-lang#114462 (interpret: add mplace_to_ref helper method)
 - rust-lang#114472 (Reword `confusable_idents` lint)
 - rust-lang#114477 (Account for `Rc` and `Arc` when suggesting to clone)

r? `@ghost`
`@rustbot` modify labels: rollup
calebcartwright pushed a commit to calebcartwright/rust that referenced this pull request Jun 22, 2024
…iaskrgr

Rollup of 9 pull requests

Successful merges:

 - rust-lang#113945 (Fix wrong span for trait selection failure error reporting)
 - rust-lang#114351 ([rustc_span][perf] Remove unnecessary string joins and allocs.)
 - rust-lang#114418 (bump parking_lot to 0.12)
 - rust-lang#114434 (Improve spans for indexing expressions)
 - rust-lang#114450 (Fix ICE failed to get layout for ReferencesError)
 - rust-lang#114461 (Fix unwrap on None)
 - rust-lang#114462 (interpret: add mplace_to_ref helper method)
 - rust-lang#114472 (Reword `confusable_idents` lint)
 - rust-lang#114477 (Account for `Rc` and `Arc` when suggesting to clone)

r? `@ghost`
`@rustbot` modify labels: rollup
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: None in compiler/rustc_hir_typeck/src/fn_ctxt/suggestions.rs
6 participants