-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
HIR printing of async fn
is broken
#60661
Comments
printing this is going to be kind of odd given that the HIR-equivalent would be to use |
That seems to be the problem :D we don't do anything: rust/src/librustc/hir/print.rs Line 396 in 407536e
Ok, so for any implementor: we need to emit Note that while |
@oli-obk even if you do that, it still won't compile: the code that |
You can use something like the |
Yeah, but we don't expose anything like that in std today, so you'd have to add it to the lowered crate... |
I'm going to close this since I think this is not a bug. See also #60663. |
I disagree (and am reopening because of that) - #60663 may not be a bug, but not showing anything, not even some non-Rust pseudosyntax, is a bug. One fun thing we could do if you want e.g. So e.g. |
expanded with
rustc --edition 2018 -Z unpretty=hir
yieldswhich is not correct. We should drop the
async
, give a return type and print some{}
around the function body.cc @cramertj
The text was updated successfully, but these errors were encountered: