Complicated type generated by circular trait associated types not shortened in some cases #109827
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
C-bug
Category: This is a bug.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
I tried this code:
I expected to see this happen:
error message appears with shortened type and a file reference to see the full type, as I've seen in other error messages like:
Instead, this happened:
enormous error message with no elision:
Note: this error comes from remarking out the trait bound on line 32 as above. That bound is meant to close the type association loop so that
<SpotId as EnumArray>::Array
is alwaysSync
, which works as long asprocess()
is not defined. A similarly long error still appears if both are left in. (I added theprocess()
function to show an error that does elide part of the type.)Meta
playground
My original error message on stable spelled out both
std::option::Option
andworld::Accessible
, so it was longer as well.The text was updated successfully, but these errors were encountered: