Skip to content

Suggest accessing field when appropriate - #81504

Merged
bors merged 9 commits into
rust-lang:masterfrom
hkmatsumoto:suggestion-field-access
Feb 1, 2021
Merged

bors merged 9 commits into
rust-lang:masterfrom
hkmatsumoto:suggestion-field-access

Conversation

@hkmatsumoto

Copy link
Copy Markdown
Contributor

Fix #81222

r? @estebank

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jan 29, 2021
Comment thread src/test/ui/suggestions/field-access.rs Resolved
@estebank

Copy link
Copy Markdown
Contributor

Minor nitpicks. Ping me when done and I'll r=me once addressed.

@hkmatsumoto

Copy link
Copy Markdown
Contributor Author

@estebank Review applied.
In addition to that, I renamed the function to suggest_accessing_field_where_appropriate to make it more descriptive.

@estebank

Copy link
Copy Markdown
Contributor

I'm really happy with the results, thanks for taking the time! r=me after tackling the last nitpick if you have the time, otherwise please file a follow up ticket so that someone can fix it after landing this PR.

@estebank

Copy link
Copy Markdown
Contributor

@bors r+

@bors

bors commented Jan 31, 2021

Copy link
Copy Markdown
Collaborator

📌 Commit f45a993 has been approved by estebank

@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 Jan 31, 2021
bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 1, 2021
…as-schievink

Rollup of 12 pull requests

Successful merges:

 - rust-lang#78641 (Let io::copy reuse BufWriter buffers)
 - rust-lang#79291 (Add error message for private fn)
 - rust-lang#81364 (Improve `rustc_mir_build::matches` docs)
 - rust-lang#81387 (Move some tests to more reasonable directories - 3)
 - rust-lang#81463 (Rename NLL* to Nll* accordingly to C-CASE)
 - rust-lang#81504 (Suggest accessing field when appropriate)
 - rust-lang#81529 (Fix invalid camel case suggestion involving unicode idents)
 - rust-lang#81536 (Indicate both start and end of pass RSS in time-passes output)
 - rust-lang#81592 (Rustdoc UI fixes)
 - rust-lang#81594 (Avoid building LLVM just for llvm-dwp)
 - rust-lang#81598 (Fix calling convention for CRT startup)
 - rust-lang#81618 (Sync rustc_codegen_cranelift)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors
bors merged commit 853cfd4 into rust-lang:master Feb 1, 2021
@rustbot rustbot added this to the 1.51.0 milestone Feb 1, 2021
@hkmatsumoto
hkmatsumoto deleted the suggestion-field-access branch February 2, 2021 17:22
m-ou-se added a commit to m-ou-se/rust that referenced this pull request Feb 2, 2021
…ewording, r=estebank

Improve wording of suggestion about accessing field

Follow-up to rust-lang#81504

The compiler at this moment suggests "you might have meant to use field `b` of type `B`", sounding like it's type `B` which has the field `b`.
r? `@estebank`
jackh726 added a commit to jackh726/rust that referenced this pull request Feb 2, 2021
…ewording, r=estebank

Improve wording of suggestion about accessing field

Follow-up to rust-lang#81504

The compiler at this moment suggests "you might have meant to use field `b` of type `B`", sounding like it's type `B` which has the field `b`.
r? ``@estebank``
jackh726 added a commit to jackh726/rust that referenced this pull request Feb 2, 2021
…ewording, r=estebank

Improve wording of suggestion about accessing field

Follow-up to rust-lang#81504

The compiler at this moment suggests "you might have meant to use field `b` of type `B`", sounding like it's type `B` which has the field `b`.
r? ```@estebank```
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.

5 participants