Commit d4134e85 by Ian Lance Taylor

compiler: more consistent error message for [...]T(x)

The message should be similar to the one for "var x [...]T",
not to the message for []T(x...).

From-SVN: r200490
parent 8e932114
......@@ -3040,7 +3040,7 @@ Parse::primary_expr(bool may_be_sink, bool may_be_composite_lit,
&& t->array_type()->length()->is_nil_expression())
{
error_at(ret->location(),
"invalid use of %<...%> in type conversion");
"use of %<[...]%> outside of array literal");
ret = Expression::make_error(loc);
}
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment