You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, when an undeclared associated type is used in a function signature within a trait body, like:
traitFoo{typeBar;//error: Baz is used but not declaredfnreturn_bool(&self,&Self::Bar,&Self::Baz) -> bool;}
it throws E0220, which isn't really helpful in this situation. Also, I found E0406 to be the more appropriate error here. This error is thrown for some feature which hasn't been implemented yet( and probably won't be), so it can be repurposed. See #34230 for more.
We could modify the error message for E0220 to include the above erroneous code, but I think it would be better to throw E0406 instead of E0220 in this situation.
Currently, when an undeclared associated type is used in a function signature within a trait body, like:
it throws E0220, which isn't really helpful in this situation. Also, I found E0406 to be the more appropriate error here. This error is thrown for some feature which hasn't been implemented yet( and probably won't be), so it can be repurposed. See #34230 for more.
We could modify the error message for
E0220
to include the above erroneous code, but I think it would be better to throwE0406
instead ofE0220
in this situation./cc @GuillaumeGomez
The text was updated successfully, but these errors were encountered: