Odd inference error reporting around generics #75398
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 made a MRE of a bug I encountered (in someone else's code actually):
I expected to see this happen: A compile error mentioning something about not being able to infer the type that
as_ref
should return, I suppose.Instead, this happened:
Meta
Tested on playground, using stable, beta, and nightly (same error for all):
Interesting variation:
Which instead yields:
(which is just a poor error, I think)
The text was updated successfully, but these errors were encountered: