aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/error.c
diff options
context:
space:
mode:
authorJason Merrill <jason@redhat.com>2009-10-17 02:11:21 -0400
committerJason Merrill <jason@gcc.gnu.org>2009-10-17 02:11:21 -0400
commitaf16209f32e1920919942ae2989fa1b857dfe73c (patch)
tree0806193b83f08725851eb08a487f668ecd2bfff2 /gcc/cp/error.c
parent6c3f4949eeda138f5ffa0377443d626951ecc0a7 (diff)
downloadgcc-af16209f32e1920919942ae2989fa1b857dfe73c.zip
gcc-af16209f32e1920919942ae2989fa1b857dfe73c.tar.gz
gcc-af16209f32e1920919942ae2989fa1b857dfe73c.tar.bz2
re PR c++/38888 ([C++0x] badly readable diagnostic output with variadic templates)
PR c++/38888 * error.c (dump_template_bindings): Wrap argument packs in {}. From-SVN: r152925
Diffstat (limited to 'gcc/cp/error.c')
-rw-r--r--gcc/cp/error.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/gcc/cp/error.c b/gcc/cp/error.c
index b50704a..ce5660f 100644
--- a/gcc/cp/error.c
+++ b/gcc/cp/error.c
@@ -311,7 +311,13 @@ dump_template_bindings (tree parms, tree args, VEC(tree,gc)* typenames)
pp_equal (cxx_pp);
pp_cxx_whitespace (cxx_pp);
if (arg)
- dump_template_argument (arg, TFF_PLAIN_IDENTIFIER);
+ {
+ if (ARGUMENT_PACK_P (arg))
+ pp_cxx_left_brace (cxx_pp);
+ dump_template_argument (arg, TFF_PLAIN_IDENTIFIER);
+ if (ARGUMENT_PACK_P (arg))
+ pp_cxx_right_brace (cxx_pp);
+ }
else
pp_string (cxx_pp, M_("<missing>"));