diff options
Diffstat (limited to 'gcc/cp/pt.c')
-rw-r--r-- | gcc/cp/pt.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index ef765738f74..f5d3851cab9 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -4661,10 +4661,14 @@ redeclare_class_template (tree type, tree parms) if (TREE_VEC_LENGTH (parms) != TREE_VEC_LENGTH (tmpl_parms)) { - error ("redeclared with %d template parameter(s)", - TREE_VEC_LENGTH (parms)); - inform (input_location, "previous declaration %q+D used %d template parameter(s)", - tmpl, TREE_VEC_LENGTH (tmpl_parms)); + error_n (input_location, TREE_VEC_LENGTH (parms), + "redeclared with %d template parameter", + "redeclared with %d template parameters", + TREE_VEC_LENGTH (parms)); + inform_n (input_location, TREE_VEC_LENGTH (tmpl_parms), + "previous declaration %q+D used %d template parameter", + "previous declaration %q+D used %d template parameters", + tmpl, TREE_VEC_LENGTH (tmpl_parms)); return false; } |