diff options
author | Jason Merrill <jason@gcc.gnu.org> | 2002-02-01 10:56:43 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2002-02-01 10:56:43 -0500 |
commit | 55ace93c8aee74fb7d9299c6aa8caa80fb1aff6f (patch) | |
tree | bee453dca234a96f14c476778b225922f349113f | |
parent | 65f36ac8689fcf7c2794b4693bd921fe6893dfe1 (diff) | |
download | gcc-55ace93c8aee74fb7d9299c6aa8caa80fb1aff6f.zip gcc-55ace93c8aee74fb7d9299c6aa8caa80fb1aff6f.tar.gz gcc-55ace93c8aee74fb7d9299c6aa8caa80fb1aff6f.tar.bz2 |
error.c (dump_scope): Don't add TFF_DECL_SPECIFIERS.
* error.c (dump_scope): Don't add TFF_DECL_SPECIFIERS.
(dump_function_decl): Always dump parms.
From-SVN: r49396
-rw-r--r-- | gcc/cp/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/cp/error.c | 5 | ||||
-rw-r--r-- | gcc/testsuite/g++.dg/template/local1.C | 4 |
3 files changed, 4 insertions, 9 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index a3aa99e..63c8747 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,9 +1,5 @@ 2002-02-01 Jason Merrill <jason@redhat.com> - PR c++/4872 - * decl.c (finish_function): Warn about a non-void function with - no return statement. - * error.c (dump_scope): Don't add TFF_DECL_SPECIFIERS. (dump_function_decl): Always dump parms. diff --git a/gcc/cp/error.c b/gcc/cp/error.c index 4642fcd..594d4e4 100644 --- a/gcc/cp/error.c +++ b/gcc/cp/error.c @@ -140,8 +140,7 @@ dump_scope (scope, flags) tree scope; int flags; { - int f = ~TFF_RETURN_TYPE & (TFF_DECL_SPECIFIERS - | (flags & (TFF_SCOPE | TFF_CHASE_TYPEDEF))); + int f = ~TFF_RETURN_TYPE & (flags & (TFF_SCOPE | TFF_CHASE_TYPEDEF)); if (scope == NULL_TREE) return; @@ -1137,7 +1136,7 @@ dump_function_decl (t, flags) dump_function_name (t, flags); - if (flags & TFF_DECL_SPECIFIERS) + if (1) { dump_parameters (parmtypes, flags); diff --git a/gcc/testsuite/g++.dg/template/local1.C b/gcc/testsuite/g++.dg/template/local1.C index 85b0056..f0897d4 100644 --- a/gcc/testsuite/g++.dg/template/local1.C +++ b/gcc/testsuite/g++.dg/template/local1.C @@ -2,7 +2,7 @@ // g(), because xref wanted the mangled name, which breaks inside a template. // Of course, the offending code is actually ill-formed anyway, so check -// for the error. +// for the error. Also check that it's formatted properly. struct A { @@ -14,7 +14,7 @@ template<class T> void A::f() struct B { void g() {} - static int x; // { dg-error "static" "" } + static int x; // { dg-error "static.*`int A::f\\(\\)::B::x'" "" } }; } |