-
Notifications
You must be signed in to change notification settings - Fork 13.1k
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
Call implementations of the Fn* traits on references #137252
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @Noratrieb (or someone else) some time within the next two weeks. 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 (
|
This comment has been minimized.
This comment has been minimized.
huh, meaning-changing formatting...? |
@workingjubilee It's not a "meaning-changing formatting" issue. For some reason, the diff in rust-lig-analyzer's comment does not match the diff in the actual logs. |
oh weird. |
The diff in rust-log-analyzer just renders weirdly for some reason. However, this still needs a test associated with it, and a pretty clear explanation of the root cause of the issue and why this fixes it. Also, yeah, please fix the formatting. I also don't think we should land this regardless, personally; @rustbot author |
Added comments and improved formatting.
The job Click to see the possible cause of the failure (guessed by this bot)
|
I fixed the formatting and added a short explanation of the change in the comments. As for the original cause of the (Issue #42736)[https://github.com//issues/42736], it is caused during the probing phase of type checking. The tests to add seem like they would be pretty straight forward. This is my first pull request, so I apologize if I have missed any steps. Where in the Unless I am actively working against someone who is already working to fix this and the other HIR typeck hacks, I don't see any harm in fixing this issue now. Thank you! |
This adds complexity to HIR typeck for a compiler-only feature. I don't think we really should be fixing this, especially because I cannot see an Thanks for the contribution, but I'm gonna opt to close it. |
The blocker for stabilizing the |
This pull request fixes Issue #42736, allowing references of
struct
s,enum
s, andunion
s to implementFn*
traits and be called. For example, the code below will compile and run properly. If approved this should also push Issue #29625 forward as well.