-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Nellshamrell/improve async error #86705
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
Changes from 4 commits
93ef6b3
0ec98df
686eaf4
0f05538
4eddf27
11dccad
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ error[E0308]: mismatched types | |
--> $DIR/dont-suggest-missing-await.rs:14:18 | ||
| | ||
LL | async fn make_u32() -> u32 { | ||
| --- checked the `Output` of this `async fn`, found opaque type | ||
| --- async functions return futures | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Love the new output! It is certainly better. I wonder if we should (maybe in the future?) give output similar to "async function There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd forgotten I had #87673 open that touches the same general place, mainly moving the I just spent a few minutes trying to accomplish what you mentioned (use the name of the method) and this is what I landed at, which I feel looks "pretty neat", but I want us to go for "easy to understand by newcomers":
I'll push the code to #87673 in a minute and you can tell me if you can pick from it so you can run with it and make it your own if there are more things we want to do here :) (because I'm not satisfied with the wording I threw in there, but the code to get the spans and names is still valid). There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh! While I was getting this working, the PR got approved and selected in a rollup (otherwise I'd kill it). We'll have to rebase this PR after that lands, sorry about that :-/ The follow up code the above screenshot came from is at bfcaf8b. Would you have the time/desire to take that and make it the best output it can be? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sure! I likely won't have time until next weekend, but I would be happy to! I'll likely open a new PR with that change. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. And ty so much for the help! |
||
... | ||
LL | take_u32(x) | ||
| ^ expected `u32`, found opaque type | ||
|
Uh oh!
There was an error while loading. Please reload this page.