-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
typeck: suggest (x.field)(...) to call struct fields even when x is a reference #33785
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
Maybe using a full autoderef loop is a better idea, since that will work in more scenarios (it looks through explicit |
Can you point me to the right API to use for that? |
That'd be |
Thanks! That was easier than I thought :) |
Looks good to me, but note tidy failures: |
Damn, I have to get into the habit of running that locally. Fixed! |
Note the failure here: https://travis-ci.org/rust-lang/rust/builds/132746890#L5411 It seems like the easiest fix would be to add another instance of |
@birkenfeld given the |
Fixes: #33784
I also removed the unnecessary span for the note.
Reviewers: is this the right way to get at the deref'd type(s)? I tried
expr_ty_adjusted
, but it claimed "no type for nodeexpr self
"...