Better error messages for sending format!
uses across thread boundaries.
#82696
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
D-terse
Diagnostics: An error or lint that doesn't give enough information about the problem at hand.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Given the following code:
The current output is:
Ideally the output should look like: I think it would be more helpful to point out which variable is being across a thread boundary. So something like,
I think it would also be helpful to point out that
ArgumentV1<'_>
comes from aformat!
invocation because it is not immediately obvious. I did run into this bug a few weeks ago, and I was only able to work this out after an internet search result returned some ofrustc
's tests.The text was updated successfully, but these errors were encountered: