提交 52e520e9 编写于 作者: R Ruud van Asseldonk

rustc: Improve misleading error message for E0282

The error can also occur in cases where a type annotation will not help.
上级 551a74dd
......@@ -290,7 +290,7 @@ pub fn maybe_report_ambiguity<'a, 'tcx>(infcx: &InferCtxt<'a, 'tcx>,
{
span_err!(infcx.tcx.sess, obligation.cause.span, E0282,
"unable to infer enough type information about `{}`; \
type annotations required",
type annotations or generic parameter binding required",
self_ty.user_string(infcx.tcx));
} else {
span_err!(infcx.tcx.sess, obligation.cause.span, E0283,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册