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

Suggest calling method on nested field when struct is missing method #96372

Merged
merged 1 commit into from
Apr 26, 2022

Conversation

compiler-errors
Copy link
Member

Similar to the suggestion to change x.field to x.nested.field, implement a similar suggestion for when x.method() should be replaced with x.nested.method().

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Apr 24, 2022
@rust-highfive
Copy link
Collaborator

r? @oli-obk

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Apr 24, 2022
@oli-obk oli-obk added the A-diagnostics Area: Messages for errors, warnings, and lints label Apr 25, 2022
@oli-obk
Copy link
Contributor

oli-obk commented Apr 25, 2022

Neat!

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Apr 25, 2022

📌 Commit dff7f25 has been approved by oli-obk

@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 25, 2022
compiler-errors added a commit to compiler-errors/rust that referenced this pull request Apr 25, 2022
…t, r=oli-obk

Suggest calling method on nested field when struct is missing method

Similar to the suggestion to change `x.field` to `x.nested.field`, implement a similar suggestion for when `x.method()` should be replaced with `x.nested.method()`.
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Apr 26, 2022
…t, r=oli-obk

Suggest calling method on nested field when struct is missing method

Similar to the suggestion to change `x.field` to `x.nested.field`, implement a similar suggestion for when `x.method()` should be replaced with `x.nested.method()`.
This was referenced Apr 26, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 26, 2022
…laumeGomez

Rollup of 8 pull requests

Successful merges:

 - rust-lang#94022 (Clarify that `Cow::into_owned` returns owned data)
 - rust-lang#94703 (Fix codegen bug in "ptx-kernel" abi related to arg passing)
 - rust-lang#95949 (Implement Default for AssertUnwindSafe)
 - rust-lang#96361 (Switch JS code to ES6)
 - rust-lang#96372 (Suggest calling method on nested field when struct is missing method)
 - rust-lang#96386 (simplify `describe_field` func in borrowck's diagnostics part)
 - rust-lang#96400 (Correct documentation for `Rvalue::ShallowInitBox`)
 - rust-lang#96415 (Remove references to git.io)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit bb6265a into rust-lang:master Apr 26, 2022
@rustbot rustbot added this to the 1.62.0 milestone Apr 26, 2022
@compiler-errors compiler-errors deleted the field-method-suggest branch August 11, 2023 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-diagnostics Area: Messages for errors, warnings, and lints 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.

5 participants