]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
pt.c (most_specialized_class): Use ngettext to determine "candidates are:" / "candida...
authorJoseph Myers <joseph@codesourcery.com>
Sat, 18 Dec 2010 19:58:57 +0000 (19:58 +0000)
committerJoseph Myers <jsm28@gcc.gnu.org>
Sat, 18 Dec 2010 19:58:57 +0000 (19:58 +0000)
* pt.c (most_specialized_class): Use ngettext to determine
"candidates are:" / "candidate is" message.

From-SVN: r168029

gcc/cp/ChangeLog
gcc/cp/pt.c

index b2a958742d083a0557d9a00741e0b8392f719be5..8ac637a09027e4805c92334167a36172ba1512b7 100644 (file)
@@ -1,3 +1,8 @@
+2010-12-18  Joseph Myers  <joseph@codesourcery.com>
+
+       * pt.c (most_specialized_class): Use ngettext to determine
+       "candidates are:" / "candidate is" message.
+
 2010-12-17  Jason Merrill  <jason@redhat.com>
 
        PR c++/46670
index 49016b3542fe3b97a5807a769c60547a23f7fdcf..c76d381929580ba7f7334035e583834cc08cd5a9 100644 (file)
@@ -16512,7 +16512,7 @@ most_specialized_class (tree type, tree tmpl, tsubst_flags_t complain)
       if (!(complain & tf_error))
        return error_mark_node;
       error ("ambiguous class template instantiation for %q#T", type);
-      str = TREE_CHAIN (list) ? _("candidates are:") : _("candidate is:");
+      str = ngettext ("candidate is:", "candidates are:", list_length (list));
       for (t = list; t; t = TREE_CHAIN (t))
         {
           error ("%s %+#T", spaces ? spaces : str, TREE_TYPE (t));