Reword type ascription note to reduce verbosity
This commit is contained in:
parent
44a086ef39
commit
d72ef21ddd
10 changed files with 11 additions and 65 deletions
|
@ -3708,11 +3708,7 @@ impl<'a> Parser<'a> {
|
|||
you annotate an expression with a type: `<expr>: <type>`");
|
||||
err.span_note(
|
||||
lhs_span,
|
||||
"this expression is annotated with type ascription...",
|
||||
);
|
||||
err.span_note(
|
||||
cur_op_span,
|
||||
"...due to this, which is why a type is expected after",
|
||||
"this expression expects an ascribed type after the colon",
|
||||
);
|
||||
err.help("this might be indicative of a syntax error elsewhere");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue