* decl.c (make_typename_type): s/parameters/arguments/.
* parser.c (cp_parser_nested_name_specifier_opt): Likewise.
* pt.c (make_pack_expansion): Correct error message.
From-SVN: r260121
+2018-05-09 Jason Merrill <jason@redhat.com>
+
+ * decl.c (make_typename_type): s/parameters/arguments/.
+ * parser.c (cp_parser_nested_name_specifier_opt): Likewise.
+ * pt.c (make_pack_expansion): Correct error message.
+
2018-05-10 Jakub Jelinek <jakub@redhat.com>
PR c++/85662
if (TREE_CODE (name) == TEMPLATE_DECL)
{
if (complain & tf_error)
- error ("%qD used without template parameters", name);
+ error ("%qD used without template arguments", name);
return error_mark_node;
}
gcc_assert (identifier_p (name));
token->location);
if (TREE_CODE (decl) == TEMPLATE_DECL)
error_at (token->location,
- "%qD used without template parameters",
+ "%qD used without template arguments",
decl);
else if (ambiguous_decls)
{
if (complain & tf_error)
{
if (TYPE_P (arg))
- error ("expansion pattern %qT contains no argument packs", arg);
+ error ("expansion pattern %qT contains no parameter packs", arg);
else
- error ("expansion pattern %qE contains no argument packs", arg);
+ error ("expansion pattern %qE contains no parameter packs", arg);
}
return error_mark_node;
}
// { dg-do compile { target c++11 } }
template <typename... T>
-struct A { alignas(int...) char c; }; // { dg-error "no argument packs|expected" }
+struct A { alignas(int...) char c; }; // { dg-error "no parameter packs|expected" }
A<int, double> a;
template<typename... Args> void g(Args... args)
{
f(const_cast<const Args*>(&args)...); // okay: ``Args'' and ``args'' are expanded
- f(5 ...); // { dg-error "contains no argument packs" }
+ f(5 ...); // { dg-error "contains no parameter packs" }
f(args); // { dg-error "5:parameter packs not expanded" }
// { dg-message "args" "note" { target *-*-* } .-1 }
f(h(args...) + args...); // okay: first ``args'' expanded within h, second ``args'' expanded within f.
template <class T> struct B { static int c; };
};
-int A::B::c; // { dg-error "parameters" }
+int A::B::c; // { dg-error "arguments" }
int A::C::d; // { dg-error "declared" }