From: jsm28 Date: Thu, 4 Mar 2010 16:17:07 +0000 (+0000) Subject: 2010-03-04 Marco Poletti X-Git-Url: http://git.sourceforge.jp/view?p=pf3gnuchains%2Fgcc-fork.git;a=commitdiff_plain;h=ed519c1c9dfdd2d9e3d135f764823b7dfee9d1db 2010-03-04 Marco Poletti * pt.c (process_partial_specialization): Use error_n instead of error. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@157229 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 926bb7b4edf..1e072301b9a 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,8 @@ +2010-03-04 Marco Poletti + + * pt.c (process_partial_specialization): Use error_n instead of + error. + 2010-03-03 Jason Merrill PR c++/12909 diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index f5d3851cab9..66e7d735ef7 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -3987,16 +3987,19 @@ process_partial_specialization (tree decl) If they are fully specialized in the specialization, that's OK. */ int j; + int count = 0; for (j = 0; j < nargs; ++j) if (tpd2.parms[j] != 0 && tpd.arg_uses_template_parms [j]) - { - error ("type %qT of template argument %qE depends " - "on template parameter(s)", - type, - arg); - break; - } + ++count; + if (count != 0) + error_n (input_location, count, + "type %qT of template argument %qE depends " + "on a template parameter", + "type %qT of template argument %qE depends " + "on template parameters", + type, + arg); } } }