Skip to content

Delegation: fix ICE with invalid MethodCall generation #138278

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 1 commit into from
Mar 10, 2025

Conversation

Bryanskiy
Copy link
Contributor

ExprKind::MethodCall is now generated instead of ExprKind::Call if

  • the resolved function has a &self argument
  • the resolved function is an associated item <- was missed before

Fixes #128190
Fixes #128119
Fixes #127916

r? @petrochenkov

@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 Mar 9, 2025
@petrochenkov petrochenkov 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 Mar 10, 2025
@rustbot
Copy link
Collaborator

rustbot commented Mar 10, 2025

This PR changes a file inside tests/crashes. If a crash was fixed, please move into the corresponding ui subdir and add 'Fixes #' to the PR description to autoclose the issue upon merge.

@petrochenkov
Copy link
Contributor

@bors r+

@bors
Copy link
Collaborator

bors commented Mar 10, 2025

📌 Commit 61122d1 has been approved by petrochenkov

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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Mar 10, 2025
bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 10, 2025
…iaskrgr

Rollup of 8 pull requests

Successful merges:

 - rust-lang#137931 (Add remark for missing `llvm-tools` component re. `rustc_private` linker failures related to not finding LLVM libraries)
 - rust-lang#138138 (Pass `InferCtxt` to `InlineAsmCtxt` to properly taint on error)
 - rust-lang#138223 (Fix post-merge workflow)
 - rust-lang#138268 (Handle empty test suites in GitHub job summary report)
 - rust-lang#138278 (Delegation: fix ICE with invalid `MethodCall` generation)
 - rust-lang#138281 (Fix O(tests) stack usage in edition 2024 mergeable doctests)
 - rust-lang#138305 (Subtree update of `rust-analyzer`)
 - rust-lang#138306 (Revert "Use workspace lints for crates in `compiler/` rust-lang#138084")

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 0d63119 into rust-lang:master Mar 10, 2025
6 checks passed
@rustbot rustbot added this to the 1.87.0 milestone Mar 10, 2025
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Mar 10, 2025
Rollup merge of rust-lang#138278 - Bryanskiy:delegation-ice-1, r=petrochenkov

Delegation: fix ICE with invalid `MethodCall` generation

`ExprKind::MethodCall` is now generated instead of `ExprKind::Call` if
- the resolved function has a `&self` argument
- the resolved function is an associated item <- was missed before

Fixes rust-lang#128190
Fixes rust-lang#128119
Fixes rust-lang#127916

r? `@petrochenkov`
@petrochenkov petrochenkov added the F-fn_delegation `#![feature(fn_delegation)]` label Mar 11, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
F-fn_delegation `#![feature(fn_delegation)]` 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
4 participants