diff options
author | Paolo Carlini <paolo.carlini@oracle.com> | 2013-08-12 22:37:20 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2013-08-12 22:37:20 +0000 |
commit | 2e507b9a9988d4cba9d03d7abb94c0f870952bba (patch) | |
tree | a50a3bcb13160b753b6b834e91070769cfe841fa /gcc | |
parent | 82ca21b50b9e5bf8496bd4f441c156b348cc163a (diff) | |
download | gcc-2e507b9a9988d4cba9d03d7abb94c0f870952bba.zip gcc-2e507b9a9988d4cba9d03d7abb94c0f870952bba.tar.gz gcc-2e507b9a9988d4cba9d03d7abb94c0f870952bba.tar.bz2 |
i386.c (ix86_function_versions): Use error + inform.
2013-08-12 Paolo Carlini <paolo.carlini@oracle.com>
* config/i386/i386.c (ix86_function_versions): Use error + inform.
/cp
2013-08-12 Paolo Carlini <paolo.carlini@oracle.com>
* decl.c (warn_extern_redeclared_static, duplicate_decls,
check_elaborated_type_specifier): Use error + inform.
* friend.c (make_friend_class): Likewise.
* semantics.c (finish_id_expression): Likewise.
/testsuite
2013-08-12 Paolo Carlini <paolo.carlini@oracle.com>
* g++.dg/cpp0x/constexpr-function2.C: Adjust for error -> inform
changes.
* g++.dg/cpp0x/constexpr-neg1.C: Likewise.
* g++.dg/cpp0x/defaulted2.C: Likewise.
* g++.dg/cpp0x/defaulted31.C: Likewise.
* g++.dg/cpp0x/error6.C: Likewise.
* g++.dg/cpp0x/gen-attrs-32.C: Likewise.
* g++.dg/cpp0x/override2.C: Likewise.
* g++.dg/cpp0x/parse1.C: Likewise.
* g++.dg/cpp0x/scoped_enum.C: Likewise.
* g++.dg/cpp0x/temp_default4.C: Likewise.
* g++.dg/ext/attrib32.C: Likewise.
* g++.dg/ext/gnu-inline-global-reject.C: Likewise.
* g++.dg/ext/mv13.C: Likewise.
* g++.dg/ext/mv7.C: Likewise.
* g++.dg/ext/mv9.C: Likewise.
* g++.dg/ext/pr57362.C: Likewise.
* g++.dg/ext/typeof10.C: Likewise.
* g++.dg/lookup/anon6.C: Likewise.
* g++.dg/lookup/crash6.C: Likewise.
* g++.dg/lookup/name-clash5.C: Likewise.
* g++.dg/lookup/name-clash6.C: Likewise.
* g++.dg/other/anon4.C: Likewise.
* g++.dg/other/error15.C: Likewise.
* g++.dg/other/error8.C: Likewise.
* g++.dg/other/redecl2.C: Likewise.
* g++.dg/parse/crash16.C: Likewise.
* g++.dg/parse/crash21.C: Likewise.
* g++.dg/parse/crash38.C: Likewise.
* g++.dg/parse/redef2.C: Likewise.
* g++.dg/parse/struct-as-enum1.C: Likewise.
* g++.dg/template/crash39.C: Likewise.
* g++.dg/template/redecl3.C: Likewise.
* g++.dg/tls/diag-3.C: Likewise.
* g++.dg/warn/Wredundant-decls-spec.C: Likewise.
* g++.old-deja/g++.benjamin/typedef01.C: Likewise.
* g++.old-deja/g++.benjamin/warn02.C: Likewise.
* g++.old-deja/g++.brendan/crash16.C: Likewise.
* g++.old-deja/g++.brendan/crash18.C: Likewise.
* g++.old-deja/g++.brendan/err-msg4.C: Likewise.
* g++.old-deja/g++.brendan/redecl1.C: Likewise.
* g++.old-deja/g++.brendan/static3.C: Likewise.
* g++.old-deja/g++.bugs/900127_02.C: Likewise.
* g++.old-deja/g++.jason/binding.C: Likewise.
* g++.old-deja/g++.jason/crash4.C: Likewise.
* g++.old-deja/g++.jason/crash7.C: Likewise.
* g++.old-deja/g++.jason/lineno.C: Likewise.
* g++.old-deja/g++.jason/scoping7.C: Likewise.
* g++.old-deja/g++.mike/misc3.C: Likewise.
* g++.old-deja/g++.mike/net44.C: Likewise.
* g++.old-deja/g++.mike/ns3.C: Likewise.
* g++.old-deja/g++.ns/alias4.C: Likewise.
* g++.old-deja/g++.ns/ns11.C: Likewise.
* g++.old-deja/g++.other/crash23.C: Likewise.
* g++.old-deja/g++.other/decl8.C: Likewise.
* g++.old-deja/g++.other/linkage3.C: Likewise.
* g++.old-deja/g++.other/typeck1.C: Likewise.
* g++.old-deja/g++.other/typedef5.C: Likewise.
* g++.old-deja/g++.pt/explicit34.C: Likewise.
* g++.old-deja/g++.pt/friend36.C: Likewise.
* obj-c++.dg/method-8.mm: Likewise.
* obj-c++.dg/tls/diag-3.mm: Likewise.
From-SVN: r201671
Diffstat (limited to 'gcc')
68 files changed, 200 insertions, 126 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 85d0527..e0a1dba 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2013-08-12 Paolo Carlini <paolo.carlini@oracle.com> + + * config/i386/i386.c (ix86_function_versions): Use error + inform. + 2013-08-12 Uros Bizjak <ubizjak@gmail.com> * config/i386/i386.md (floatunssi<mode>2 expand): Use MODEF mode diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 509cb6e..842f993 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -29870,8 +29870,8 @@ ix86_function_versions (tree fn1, tree fn2) error_at (DECL_SOURCE_LOCATION (fn2), "missing %<target%> attribute for multi-versioned %D", fn2); - error_at (DECL_SOURCE_LOCATION (fn1), - "previous declaration of %D", fn1); + inform (DECL_SOURCE_LOCATION (fn1), + "previous declaration of %D", fn1); /* Prevent diagnosing of the same error multiple times. */ DECL_ATTRIBUTES (fn2) = tree_cons (get_identifier ("target"), diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index fc10e95..a7462af 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,10 @@ +2013-08-12 Paolo Carlini <paolo.carlini@oracle.com> + + * decl.c (warn_extern_redeclared_static, duplicate_decls, + check_elaborated_type_specifier): Use error + inform. + * friend.c (make_friend_class): Likewise. + * semantics.c (finish_id_expression): Likewise. + 2013-08-09 Paolo Carlini <paolo.carlini@oracle.com> Revert: diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index d49ed29..16f751c 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -1146,8 +1146,9 @@ warn_extern_redeclared_static (tree newdecl, tree olddecl) && DECL_ARTIFICIAL (olddecl)) return; - permerror (input_location, "%qD was declared %<extern%> and later %<static%>", newdecl); - permerror (input_location, "previous declaration of %q+D", olddecl); + if (permerror (input_location, + "%qD was declared %<extern%> and later %<static%>", newdecl)) + inform (input_location, "previous declaration of %q+D", olddecl); } /* NEW_DECL is a redeclaration of OLD_DECL; both are functions or @@ -1287,19 +1288,19 @@ duplicate_decls (tree newdecl, tree olddecl, bool newdecl_is_friend) && DECL_UNINLINABLE (olddecl) && lookup_attribute ("noinline", DECL_ATTRIBUTES (olddecl))) { - warning (OPT_Wattributes, "function %q+D redeclared as inline", - newdecl); - warning (OPT_Wattributes, "previous declaration of %q+D " - "with attribute noinline", olddecl); + if (warning (OPT_Wattributes, "function %q+D redeclared as inline", + newdecl)) + inform (input_location, "previous declaration of %q+D " + "with attribute noinline", olddecl); } else if (DECL_DECLARED_INLINE_P (olddecl) && DECL_UNINLINABLE (newdecl) && lookup_attribute ("noinline", DECL_ATTRIBUTES (newdecl))) { - warning (OPT_Wattributes, "function %q+D redeclared with " - "attribute noinline", newdecl); - warning (OPT_Wattributes, "previous declaration of %q+D was inline", - olddecl); + if (warning (OPT_Wattributes, "function %q+D redeclared with " + "attribute noinline", newdecl)) + inform (input_location, "previous declaration of %q+D was inline", + olddecl); } } @@ -1485,7 +1486,7 @@ duplicate_decls (tree newdecl, tree olddecl, bool newdecl_is_friend) error ("%q#D redeclared as different kind of symbol", newdecl); if (TREE_CODE (olddecl) == TREE_LIST) olddecl = TREE_VALUE (olddecl); - error ("previous declaration of %q+#D", olddecl); + inform (input_location, "previous declaration of %q+#D", olddecl); return error_mark_node; } @@ -1550,7 +1551,8 @@ duplicate_decls (tree newdecl, tree olddecl, bool newdecl_is_friend) else { error ("conflicting declaration %q#D", newdecl); - error ("%q+D has a previous declaration as %q#D", olddecl, olddecl); + inform (input_location, + "%q+D has a previous declaration as %q#D", olddecl, olddecl); return error_mark_node; } } @@ -1613,9 +1615,10 @@ duplicate_decls (tree newdecl, tree olddecl, bool newdecl_is_friend) { error_at (DECL_SOURCE_LOCATION (newdecl), errmsg, newdecl); if (DECL_NAME (olddecl) != NULL_TREE) - error ((DECL_INITIAL (olddecl) && namespace_bindings_p ()) - ? G_("%q+#D previously defined here") - : G_("%q+#D previously declared here"), olddecl); + inform (input_location, + (DECL_INITIAL (olddecl) && namespace_bindings_p ()) + ? G_("%q+#D previously defined here") + : G_("%q+#D previously declared here"), olddecl); return error_mark_node; } else if (TREE_CODE (olddecl) == FUNCTION_DECL @@ -1759,8 +1762,10 @@ duplicate_decls (tree newdecl, tree olddecl, bool newdecl_is_friend) && (! DECL_TEMPLATE_SPECIALIZATION (newdecl) || DECL_TEMPLATE_SPECIALIZATION (olddecl))) { - warning (OPT_Wredundant_decls, "redundant redeclaration of %qD in same scope", newdecl); - warning (OPT_Wredundant_decls, "previous declaration of %q+D", olddecl); + if (warning (OPT_Wredundant_decls, + "redundant redeclaration of %qD in same scope", + newdecl)) + inform (input_location, "previous declaration of %q+D", olddecl); } if (!(DECL_TEMPLATE_INSTANTIATION (olddecl) @@ -11836,14 +11841,14 @@ check_elaborated_type_specifier (enum tag_types tag_code, && tag_code != typename_type) { error ("%qT referred to as %qs", type, tag_name (tag_code)); - error ("%q+T has a previous declaration here", type); + inform (input_location, "%q+T has a previous declaration here", type); return error_mark_node; } else if (TREE_CODE (type) != ENUMERAL_TYPE && tag_code == enum_type) { error ("%qT referred to as enum", type); - error ("%q+T has a previous declaration here", type); + inform (input_location, "%q+T has a previous declaration here", type); return error_mark_node; } else if (!allow_template_p diff --git a/gcc/cp/friend.c b/gcc/cp/friend.c index 3e018e8..779dac9 100644 --- a/gcc/cp/friend.c +++ b/gcc/cp/friend.c @@ -327,7 +327,7 @@ make_friend_class (tree type, tree friend_type, bool complain) { error ("%qT is not a member class template of %qT", name, ctype); - error ("%q+D declared here", decl); + inform (input_location, "%q+D declared here", decl); return; } if (!template_member_p && (TREE_CODE (decl) != TYPE_DECL @@ -335,7 +335,7 @@ make_friend_class (tree type, tree friend_type, bool complain) { error ("%qT is not a nested class of %qT", name, ctype); - error ("%q+D declared here", decl); + inform (input_location, "%q+D declared here", decl); return; } diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index 3bc09b9..fa47db7 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -3131,7 +3131,7 @@ finish_id_expression (tree id_expression, error (VAR_P (decl) ? G_("use of local variable with automatic storage from containing function") : G_("use of parameter from containing function")); - error (" %q+#D declared here", decl); + inform (input_location, "%q+#D declared here", decl); return error_mark_node; } } diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index da7f54f..80ed59d 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,68 @@ +2013-08-12 Paolo Carlini <paolo.carlini@oracle.com> + + * g++.dg/cpp0x/constexpr-function2.C: Adjust for error -> inform + changes. + * g++.dg/cpp0x/constexpr-neg1.C: Likewise. + * g++.dg/cpp0x/defaulted2.C: Likewise. + * g++.dg/cpp0x/defaulted31.C: Likewise. + * g++.dg/cpp0x/error6.C: Likewise. + * g++.dg/cpp0x/gen-attrs-32.C: Likewise. + * g++.dg/cpp0x/override2.C: Likewise. + * g++.dg/cpp0x/parse1.C: Likewise. + * g++.dg/cpp0x/scoped_enum.C: Likewise. + * g++.dg/cpp0x/temp_default4.C: Likewise. + * g++.dg/ext/attrib32.C: Likewise. + * g++.dg/ext/gnu-inline-global-reject.C: Likewise. + * g++.dg/ext/mv13.C: Likewise. + * g++.dg/ext/mv7.C: Likewise. + * g++.dg/ext/mv9.C: Likewise. + * g++.dg/ext/pr57362.C: Likewise. + * g++.dg/ext/typeof10.C: Likewise. + * g++.dg/lookup/anon6.C: Likewise. + * g++.dg/lookup/crash6.C: Likewise. + * g++.dg/lookup/name-clash5.C: Likewise. + * g++.dg/lookup/name-clash6.C: Likewise. + * g++.dg/other/anon4.C: Likewise. + * g++.dg/other/error15.C: Likewise. + * g++.dg/other/error8.C: Likewise. + * g++.dg/other/redecl2.C: Likewise. + * g++.dg/parse/crash16.C: Likewise. + * g++.dg/parse/crash21.C: Likewise. + * g++.dg/parse/crash38.C: Likewise. + * g++.dg/parse/redef2.C: Likewise. + * g++.dg/parse/struct-as-enum1.C: Likewise. + * g++.dg/template/crash39.C: Likewise. + * g++.dg/template/redecl3.C: Likewise. + * g++.dg/tls/diag-3.C: Likewise. + * g++.dg/warn/Wredundant-decls-spec.C: Likewise. + * g++.old-deja/g++.benjamin/typedef01.C: Likewise. + * g++.old-deja/g++.benjamin/warn02.C: Likewise. + * g++.old-deja/g++.brendan/crash16.C: Likewise. + * g++.old-deja/g++.brendan/crash18.C: Likewise. + * g++.old-deja/g++.brendan/err-msg4.C: Likewise. + * g++.old-deja/g++.brendan/redecl1.C: Likewise. + * g++.old-deja/g++.brendan/static3.C: Likewise. + * g++.old-deja/g++.bugs/900127_02.C: Likewise. + * g++.old-deja/g++.jason/binding.C: Likewise. + * g++.old-deja/g++.jason/crash4.C: Likewise. + * g++.old-deja/g++.jason/crash7.C: Likewise. + * g++.old-deja/g++.jason/lineno.C: Likewise. + * g++.old-deja/g++.jason/scoping7.C: Likewise. + * g++.old-deja/g++.mike/misc3.C: Likewise. + * g++.old-deja/g++.mike/net44.C: Likewise. + * g++.old-deja/g++.mike/ns3.C: Likewise. + * g++.old-deja/g++.ns/alias4.C: Likewise. + * g++.old-deja/g++.ns/ns11.C: Likewise. + * g++.old-deja/g++.other/crash23.C: Likewise. + * g++.old-deja/g++.other/decl8.C: Likewise. + * g++.old-deja/g++.other/linkage3.C: Likewise. + * g++.old-deja/g++.other/typeck1.C: Likewise. + * g++.old-deja/g++.other/typedef5.C: Likewise. + * g++.old-deja/g++.pt/explicit34.C: Likewise. + * g++.old-deja/g++.pt/friend36.C: Likewise. + * obj-c++.dg/method-8.mm: Likewise. + * obj-c++.dg/tls/diag-3.mm: Likewise. + 2013-08-12 Perez Read <netfirewall@gmail.com> PR target/58132 diff --git a/gcc/testsuite/g++.dg/cpp0x/constexpr-function2.C b/gcc/testsuite/g++.dg/cpp0x/constexpr-function2.C index 5a2ec76..6403ea1 100644 --- a/gcc/testsuite/g++.dg/cpp0x/constexpr-function2.C +++ b/gcc/testsuite/g++.dg/cpp0x/constexpr-function2.C @@ -38,7 +38,7 @@ constexpr int g(int x, int n) // error: body not just ‘‘return expr’’ } // { dg-error "not a return-statement" } constexpr int -bar(int x, int y) { return x + y + x * y; } // { dg-error "previously" } +bar(int x, int y) { return x + y + x * y; } // { dg-message "previously" } int bar(int x, int y) // { dg-error "redefinition" } { return x * 2 + 3 * y; } diff --git a/gcc/testsuite/g++.dg/cpp0x/constexpr-neg1.C b/gcc/testsuite/g++.dg/cpp0x/constexpr-neg1.C index 8294afa..c27615f 100644 --- a/gcc/testsuite/g++.dg/cpp0x/constexpr-neg1.C +++ b/gcc/testsuite/g++.dg/cpp0x/constexpr-neg1.C @@ -50,7 +50,7 @@ private: bool flag; }; // OK -constexpr int bar(int x, int y) // { dg-error "previously defined here" } +constexpr int bar(int x, int y) // { dg-message "previously defined here" } { return x + y + x*y; } // ... // error: redefinition of bar diff --git a/gcc/testsuite/g++.dg/cpp0x/defaulted2.C b/gcc/testsuite/g++.dg/cpp0x/defaulted2.C index ce551a3..57f74e8 100644 --- a/gcc/testsuite/g++.dg/cpp0x/defaulted2.C +++ b/gcc/testsuite/g++.dg/cpp0x/defaulted2.C @@ -6,13 +6,13 @@ void f() = delete; // { dg-error "deleted" } struct A { - A() { } // { dg-error "previous" } + A() { } // { dg-message "previous" } void f() = default; // { dg-error "default" } }; A::A() = default; // { dg-error "redefinition" } -void g() {} // { dg-error "previous" } +void g() {} // { dg-message "previous" } void g() = delete; // { dg-error "redefinition" } struct B // { dg-message "user-provided default constructor" } diff --git a/gcc/testsuite/g++.dg/cpp0x/defaulted31.C b/gcc/testsuite/g++.dg/cpp0x/defaulted31.C index de6a298..c76a0f2 100644 --- a/gcc/testsuite/g++.dg/cpp0x/defaulted31.C +++ b/gcc/testsuite/g++.dg/cpp0x/defaulted31.C @@ -3,7 +3,7 @@ struct A { - A() { } // { dg-error "defined" } + A() { } // { dg-message "defined" } ~A() = default; // { dg-error "defaulted" } }; diff --git a/gcc/testsuite/g++.dg/cpp0x/error6.C b/gcc/testsuite/g++.dg/cpp0x/error6.C index 3515652..3b45795 100644 --- a/gcc/testsuite/g++.dg/cpp0x/error6.C +++ b/gcc/testsuite/g++.dg/cpp0x/error6.C @@ -2,7 +2,7 @@ // { dg-options -std=c++0x } template<typename C> -auto g(C& c) -> decltype (c.f()) { return c.f(); } // { dg-error "decltype .c\\.f" } +auto g(C& c) -> decltype (c.f()) { return c.f(); } // { dg-message "decltype .c\\.f" } template<typename C> auto g(C& c) -> decltype (c.f()) { return c.f(); } // { dg-error "decltype .c\\.f" } diff --git a/gcc/testsuite/g++.dg/cpp0x/gen-attrs-32.C b/gcc/testsuite/g++.dg/cpp0x/gen-attrs-32.C index f344661..6a1b235d 100644 --- a/gcc/testsuite/g++.dg/cpp0x/gen-attrs-32.C +++ b/gcc/testsuite/g++.dg/cpp0x/gen-attrs-32.C @@ -13,7 +13,7 @@ void bar() typedef union U1 { int i; } U2 [[gnu::transparent_union]]; // { dg-warning "ignored" } -static void foo2(U1) {} // { dg-error "previously defined" } +static void foo2(U1) {} // { dg-message "previously defined" } static void foo2(U2) {} // { dg-error "redefinition" } void bar2(U1 u1, U2 u2) diff --git a/gcc/testsuite/g++.dg/cpp0x/override2.C b/gcc/testsuite/g++.dg/cpp0x/override2.C index 4d5a412..1a7a36e 100644 --- a/gcc/testsuite/g++.dg/cpp0x/override2.C +++ b/gcc/testsuite/g++.dg/cpp0x/override2.C @@ -44,7 +44,7 @@ int main() B2 final2 = final; struct B2 {}; // { dg-error "redefinition" } struct B2 final; // { dg-error "redeclaration" } - struct B2 override; // { dg-error "previously declared here" } + struct B2 override; // { dg-message "previously declared here" } struct B2 final {}; // { dg-error "redefinition" } struct B2 override {}; // { dg-error "cannot specify 'override' for a class" } B2 override{}; // { dg-error "redeclaration" } diff --git a/gcc/testsuite/g++.dg/cpp0x/parse1.C b/gcc/testsuite/g++.dg/cpp0x/parse1.C index 4181185..4fa7461 100644 --- a/gcc/testsuite/g++.dg/cpp0x/parse1.C +++ b/gcc/testsuite/g++.dg/cpp0x/parse1.C @@ -1,5 +1,5 @@ // PR c++/43509 // { dg-options "-std=c++0x" } -typedef int B; // { dg-error "" } +typedef int B; // { dg-message "" } B::B() {} // { dg-error "" } diff --git a/gcc/testsuite/g++.dg/cpp0x/scoped_enum.C b/gcc/testsuite/g++.dg/cpp0x/scoped_enum.C index 4b0317c..20391eb 100644 --- a/gcc/testsuite/g++.dg/cpp0x/scoped_enum.C +++ b/gcc/testsuite/g++.dg/cpp0x/scoped_enum.C @@ -6,7 +6,7 @@ enum class Color1 { }; enum struct Color2 { - Red, // { dg-error "previously declared here" } + Red, // { dg-message "previously declared here" } Orange, Yellow, Green, diff --git a/gcc/testsuite/g++.dg/cpp0x/temp_default4.C b/gcc/testsuite/g++.dg/cpp0x/temp_default4.C index f1e254c..aa2ad58 100644 --- a/gcc/testsuite/g++.dg/cpp0x/temp_default4.C +++ b/gcc/testsuite/g++.dg/cpp0x/temp_default4.C @@ -2,7 +2,7 @@ class X { template<typename T = int> friend void f(X) { } - template<typename T> friend void g(X); // { dg-error "previously declared here" } + template<typename T> friend void g(X); // { dg-message "previously declared here" } template<typename T = int> friend void h(X); // { dg-error "function template friend" } }; diff --git a/gcc/testsuite/g++.dg/ext/attrib32.C b/gcc/testsuite/g++.dg/ext/attrib32.C index e4dfe4e..31a92b8 100644 --- a/gcc/testsuite/g++.dg/ext/attrib32.C +++ b/gcc/testsuite/g++.dg/ext/attrib32.C @@ -12,7 +12,7 @@ void bar() typedef union U1 { int i; } U2 __attribute__((transparent_union)); // { dg-warning "ignored" } -static void foo2(U1) {} // { dg-error "previously defined" } +static void foo2(U1) {} // { dg-message "previously defined" } static void foo2(U2) {} // { dg-error "redefinition" } void bar2(U1 u1, U2 u2) diff --git a/gcc/testsuite/g++.dg/ext/gnu-inline-global-reject.C b/gcc/testsuite/g++.dg/ext/gnu-inline-global-reject.C index fc7385d..7e84fa7 100644 --- a/gcc/testsuite/g++.dg/ext/gnu-inline-global-reject.C +++ b/gcc/testsuite/g++.dg/ext/gnu-inline-global-reject.C @@ -10,47 +10,47 @@ #undef fn #define fn pfx(func_decl_inline_before) -decl(inline, fn) // { dg-error "previous" "" } +decl(inline, fn) // { dg-message "previous" "" } gnuindef(fn, 0) // { dg-error "redeclared" "" } #undef fn #define fn pfx(func_decl_inline_after) -gnuindef(fn, 0) // { dg-error "previous" "" } +gnuindef(fn, 0) // { dg-message "previous" "" } decl(inline, fn) // { dg-error "redeclared" "" } #undef fn #define fn pfx(func_def_gnuin_redef) -gnuindef(fn, 0) // { dg-error "previous" "" } +gnuindef(fn, 0) // { dg-message "previous" "" } gnuindef(fn, 1) // { dg-error "redefinition" "" } #undef fn #define fn pfx(func_def_inline_redef) -def(inline, fn, 0) // { dg-error "previous" "" } +def(inline, fn, 0) // { dg-message "previous" "" } def(inline, fn, 1) // { dg-error "redefinition" "" } #undef fn #define fn pfx(func_def_inline_after) -gnuindef(fn, 0) // { dg-error "previous" "" } +gnuindef(fn, 0) // { dg-message "previous" "" } def(inline, fn, 1) // { dg-error "redeclare" "" } #undef fn #define fn pfx(func_def_inline_before) -def(inline, fn, 0) // { dg-error "previous" "" } +def(inline, fn, 0) // { dg-message "previous" "" } gnuindef(fn, 1) // { dg-error "redefinition" "" } #undef fn #define fn pfx(func_def_before) -def(, fn, 0) // { dg-error "previous" "" } +def(, fn, 0) // { dg-message "previous" "" } gnuindef(fn, 1) // { dg-error "redefinition" "" } #undef fn #define fn pfx(func_decl_static_inline_before) -decl(static inline, fn) // { dg-error "previous" "" } +decl(static inline, fn) // { dg-message "previous" "" } gnuindef(fn, 0) // { dg-error "redeclared" "" } #undef fn #define fn pfx(func_def_static_inline_after) decl(static, fn) -gnuindef(fn, 0) // { dg-error "previous" "" } +gnuindef(fn, 0) // { dg-message "previous" "" } decl(static, fn) def(static inline, fn, 1) // { dg-error "redeclare" "" } diff --git a/gcc/testsuite/g++.dg/ext/mv13.C b/gcc/testsuite/g++.dg/ext/mv13.C index 9554993..5674d19 100644 --- a/gcc/testsuite/g++.dg/ext/mv13.C +++ b/gcc/testsuite/g++.dg/ext/mv13.C @@ -5,7 +5,7 @@ extern "C" __attribute__ ((target ("default"))) -int foo () // { dg-error "previously defined here" } +int foo () // { dg-message "previously defined here" } { return 0; } diff --git a/gcc/testsuite/g++.dg/ext/mv7.C b/gcc/testsuite/g++.dg/ext/mv7.C index d378402..64c04fa 100644 --- a/gcc/testsuite/g++.dg/ext/mv7.C +++ b/gcc/testsuite/g++.dg/ext/mv7.C @@ -2,7 +2,7 @@ // { dg-options "" } __attribute__((target ("default"))) -void foo (void) // { dg-error "previously defined here" } +void foo (void) // { dg-message "previously defined here" } { } diff --git a/gcc/testsuite/g++.dg/ext/mv9.C b/gcc/testsuite/g++.dg/ext/mv9.C index 53ee995..c59651e 100644 --- a/gcc/testsuite/g++.dg/ext/mv9.C +++ b/gcc/testsuite/g++.dg/ext/mv9.C @@ -3,7 +3,7 @@ void foo (); void foo () __attribute__((target ("sse4"))); -void foo () __attribute__((target ("default"))); // { dg-error "previous declaration" } +void foo () __attribute__((target ("default"))); // { dg-message "previous declaration" } void foo () // { dg-error "attribute for multi-versioned" } { } diff --git a/gcc/testsuite/g++.dg/ext/pr57362.C b/gcc/testsuite/g++.dg/ext/pr57362.C index 67f9685..71c53d3 100644 --- a/gcc/testsuite/g++.dg/ext/pr57362.C +++ b/gcc/testsuite/g++.dg/ext/pr57362.C @@ -193,7 +193,6 @@ int foo(void) { return 1; } } /* { dg-prune-output "attribute.* is unknown" } */ -/* { dg-prune-output "redefinition of int foo" } */ -/* { dg-prune-output "previous declaration of int foo" } */ -/* { dg-prune-output "int foo.* previously defined here" } */ +/* { dg-prune-output "missing 'target' attribute*" } */ +/* { dg-prune-output "redefinition of 'int foo" } */ /* { dg-prune-output "No dispatcher found for" } */ diff --git a/gcc/testsuite/g++.dg/ext/typeof10.C b/gcc/testsuite/g++.dg/ext/typeof10.C index 1b357ad..6145385 100644 --- a/gcc/testsuite/g++.dg/ext/typeof10.C +++ b/gcc/testsuite/g++.dg/ext/typeof10.C @@ -5,7 +5,7 @@ template<int> struct A { void foo() { - typedef int T; // { dg-error "previous" } + typedef int T; // { dg-message "previous" } typedef __typeof__(*this) T; // { dg-error "conflicting" } } }; diff --git a/gcc/testsuite/g++.dg/lookup/anon6.C b/gcc/testsuite/g++.dg/lookup/anon6.C index 09fa7f8..7c5a968 100644 --- a/gcc/testsuite/g++.dg/lookup/anon6.C +++ b/gcc/testsuite/g++.dg/lookup/anon6.C @@ -1,11 +1,11 @@ -extern int v1; // { dg-error "declared" } +extern int v1; // { dg-message "declared" } static union { int v1; }; // { dg-error "redeclaration" } -static union { int v2; }; // { dg-error "declared" } +static union { int v2; }; // { dg-message "declared" } extern int v2; // { dg-error "redeclaration" } -int v3; // { dg-error "declared" } +int v3; // { dg-message "declared" } static union { int v3; }; // { dg-error "redeclaration" } -static union { int v4; }; // { dg-error "declared" } +static union { int v4; }; // { dg-message "declared" } static union { int v4; }; // { dg-error "redeclaration" } diff --git a/gcc/testsuite/g++.dg/lookup/crash6.C b/gcc/testsuite/g++.dg/lookup/crash6.C index 0e49324..b8481be 100644 --- a/gcc/testsuite/g++.dg/lookup/crash6.C +++ b/gcc/testsuite/g++.dg/lookup/crash6.C @@ -4,5 +4,5 @@ // PR c++/18652: ICE redeclaring variable as template. -int A; // { dg-error "previous declaration" } +int A; // { dg-message "previous declaration" } template<int> struct A; // { dg-error "different kind of symbol" } diff --git a/gcc/testsuite/g++.dg/lookup/name-clash5.C b/gcc/testsuite/g++.dg/lookup/name-clash5.C index 7f220d8..74595c2 100644 --- a/gcc/testsuite/g++.dg/lookup/name-clash5.C +++ b/gcc/testsuite/g++.dg/lookup/name-clash5.C @@ -7,7 +7,7 @@ // declarative region (7.3.2, clause 14). ]" namespace N -{ // { dg-error "previous declaration" } +{ // { dg-message "previous declaration" } } class N; // { dg-error "redeclared" } diff --git a/gcc/testsuite/g++.dg/lookup/name-clash6.C b/gcc/testsuite/g++.dg/lookup/name-clash6.C index 63a0b15..6918142 100644 --- a/gcc/testsuite/g++.dg/lookup/name-clash6.C +++ b/gcc/testsuite/g++.dg/lookup/name-clash6.C @@ -6,7 +6,7 @@ // "[Note: a namespace name or a class template name must be unique in its // declarative region (7.3.2, clause 14). ]" -class N; // { dg-error "previous declaration" } +class N; // { dg-message "previous declaration" } namespace N { // { dg-error "redeclared" } diff --git a/gcc/testsuite/g++.dg/other/anon4.C b/gcc/testsuite/g++.dg/other/anon4.C index 571f4ae..37df228 100644 --- a/gcc/testsuite/g++.dg/other/anon4.C +++ b/gcc/testsuite/g++.dg/other/anon4.C @@ -3,6 +3,6 @@ void foo() { - int i; // { dg-error "previously" } + int i; // { dg-message "previously" } union { int i; }; // { dg-error "redeclaration" } } diff --git a/gcc/testsuite/g++.dg/other/error15.C b/gcc/testsuite/g++.dg/other/error15.C index 3601852..d218c13 100644 --- a/gcc/testsuite/g++.dg/other/error15.C +++ b/gcc/testsuite/g++.dg/other/error15.C @@ -3,39 +3,39 @@ extern void g0 (int a, int b); extern void g1 (int a, float b); -extern void f0 (int a, // { dg-error "previous" } +extern void f0 (int a, // { dg-message "previous" } int a); // { dg-error "redefinition" } -extern void f1 (int a, // { dg-error "previous" } +extern void f1 (int a, // { dg-message "previous" } float a); // { dg-error "conflicting" } -extern void f3 (int a, int b, int c, // { dg-error "previous" } +extern void f3 (int a, int b, int c, // { dg-message "previous" } int a); // { dg-error "redefinition" } -extern void f4 (int a, int b, int c, // { dg-error "previous" } +extern void f4 (int a, int b, int c, // { dg-message "previous" } int a, // { dg-error "redefinition" } int a); // { dg-error "redefinition" } -extern void f5 (int a, int b, int c, int d, int e, int f, int g, int h, // { dg-error "previous" } +extern void f5 (int a, int b, int c, int d, int e, int f, int g, int h, // { dg-message "previous" } int a, // { dg-error "redefinition" } int i, int j, int k, int l, int m, int n, int o, int p, int q, int r, int s, int t, int u, int v, int w, int x, int y, int z); -extern void f6 (int a, int, int, int, int, int, int, int, int, int, int, // { dg-error "previous" } +extern void f6 (int a, int, int, int, int, int, int, int, int, int, int, // { dg-message "previous" } int a, // { dg-error "redefinition" } int, int, int, int, int, int, int, int, int, int, int, float, float, float, float, float, float, float, float, int); -extern void f7 (void (*a)(int), // { dg-error "previous" } +extern void f7 (void (*a)(int), // { dg-message "previous" } void (*a)(int)); // { dg-error "redefinition" } -extern void f8 (float (*a)(int), // { dg-error "previous" } +extern void f8 (float (*a)(int), // { dg-message "previous" } int (*a)(float)); // { dg-error "conflicting" } -extern void f9 (int a, // { dg-error "previous" } +extern void f9 (int a, // { dg-message "previous" } int a, // { dg-error "redefinition" } int a); // { dg-error "redefinition" } -extern void f10 (int a, // { dg-error "previous" } - int b, // { dg-error "previous" } - int c, // { dg-error "previous" } +extern void f10 (int a, // { dg-message "previous" } + int b, // { dg-message "previous" } + int c, // { dg-message "previous" } int c, // { dg-error "redefinition" } int b, // { dg-error "redefinition" } int a); // { dg-error "redefinition" } @@ -43,7 +43,7 @@ extern void f10 (int a, // { dg-error "previous" } class C1 { public: void C1_g0 (int a, int b); - void C1_f0 (int a, // { dg-error "previous" } + void C1_f0 (int a, // { dg-message "previous" } int a); // { dg-error "redefinition" } }; @@ -51,6 +51,6 @@ template <class T> class C2 { public: void C2_g0 (T a, T b); - void C2_f0 (T a, // { dg-error "previous" } + void C2_f0 (T a, // { dg-message "previous" } T a); // { dg-error "redefinition" } }; diff --git a/gcc/testsuite/g++.dg/other/error8.C b/gcc/testsuite/g++.dg/other/error8.C index 9246c2a..116a684 100644 --- a/gcc/testsuite/g++.dg/other/error8.C +++ b/gcc/testsuite/g++.dg/other/error8.C @@ -5,7 +5,7 @@ void foo(void) { - union { int alpha; int beta; }; // { dg-error "previous declaration" } + union { int alpha; int beta; }; // { dg-message "previous declaration" } double alpha; // { dg-error "conflicting declaration" } } diff --git a/gcc/testsuite/g++.dg/other/redecl2.C b/gcc/testsuite/g++.dg/other/redecl2.C index 591c258..6c8913c1 100644 --- a/gcc/testsuite/g++.dg/other/redecl2.C +++ b/gcc/testsuite/g++.dg/other/redecl2.C @@ -7,5 +7,5 @@ struct S { virtual int foo() = 0; }; -int S::foo() { return 0; } // { dg-error "defined here" } +int S::foo() { return 0; } // { dg-message "defined here" } int S::foo() { return 0; } // { dg-error "redefinition" } diff --git a/gcc/testsuite/g++.dg/parse/crash16.C b/gcc/testsuite/g++.dg/parse/crash16.C index dc8f7a6..c7da3eb 100644 --- a/gcc/testsuite/g++.dg/parse/crash16.C +++ b/gcc/testsuite/g++.dg/parse/crash16.C @@ -1,7 +1,7 @@ // PR c++/16971 namespace N { - int i; // { dg-error "" } + int i; // { dg-message "" } // By checking for an explicit keyword on the next line we avoid // matching an ICE message. int i; // { dg-error "redefinition" } diff --git a/gcc/testsuite/g++.dg/parse/crash21.C b/gcc/testsuite/g++.dg/parse/crash21.C index 283f6b4..623bbec 100644 --- a/gcc/testsuite/g++.dg/parse/crash21.C +++ b/gcc/testsuite/g++.dg/parse/crash21.C @@ -1,6 +1,6 @@ namespace N { - struct A; // { dg-error "previous declaration" "" } + struct A; // { dg-message "previous declaration" "" } } template<int I> diff --git a/gcc/testsuite/g++.dg/parse/crash38.C b/gcc/testsuite/g++.dg/parse/crash38.C index 724f9b8..7a0c265 100644 --- a/gcc/testsuite/g++.dg/parse/crash38.C +++ b/gcc/testsuite/g++.dg/parse/crash38.C @@ -1,11 +1,11 @@ /* PR c++/33207 */ /* This would not ICE. */ -namespace M { } /* { dg-error "previous declaration" } */ +namespace M { } /* { dg-message "previous declaration" } */ struct M; /* { dg-error "redeclared as different kind of symbol" } */ M *p; /* { dg-error "does not name a type" } */ /* This would ICE when processing 'p'. */ -namespace N { } /* { dg-error "previous declaration" } */ +namespace N { } /* { dg-message "previous declaration" } */ struct N; /* { dg-error "redeclared as different kind of symbol" } */ struct N* p; /* { dg-error "redeclared as different kind of symbol|invalid type" } */ diff --git a/gcc/testsuite/g++.dg/parse/redef2.C b/gcc/testsuite/g++.dg/parse/redef2.C index 2435672..3ab3667 100644 --- a/gcc/testsuite/g++.dg/parse/redef2.C +++ b/gcc/testsuite/g++.dg/parse/redef2.C @@ -1,6 +1,6 @@ // { dg-do compile } -char * d [10]; // { dg-error "8: 'd' has a previous declaration as" } +char * d [10]; // { dg-message "8: 'd' has a previous declaration as" } char e [15][10]; int (*f)(); diff --git a/gcc/testsuite/g++.dg/parse/struct-as-enum1.C b/gcc/testsuite/g++.dg/parse/struct-as-enum1.C index f58c738..a6cb6b5 100644 --- a/gcc/testsuite/g++.dg/parse/struct-as-enum1.C +++ b/gcc/testsuite/g++.dg/parse/struct-as-enum1.C @@ -4,7 +4,7 @@ namespace N { - struct A {}; // { dg-error "previous declaration" } + struct A {}; // { dg-message "previous declaration" } } typedef enum N::A B; // { dg-error "enum|invalid type" } diff --git a/gcc/testsuite/g++.dg/template/crash39.C b/gcc/testsuite/g++.dg/template/crash39.C index ddecc17..840255c 100644 --- a/gcc/testsuite/g++.dg/template/crash39.C +++ b/gcc/testsuite/g++.dg/template/crash39.C @@ -1,6 +1,6 @@ // PR c++/22405 -template <typename T> void foo(T &arg) { // { dg-error "declared" } +template <typename T> void foo(T &arg) { // { dg-message "declared" } arg+=1; } diff --git a/gcc/testsuite/g++.dg/template/redecl3.C b/gcc/testsuite/g++.dg/template/redecl3.C index 029f9e6..faa29bf 100644 --- a/gcc/testsuite/g++.dg/template/redecl3.C +++ b/gcc/testsuite/g++.dg/template/redecl3.C @@ -3,5 +3,5 @@ // { dg-do compile } -int foo; // { dg-error "previous declaration" } +int foo; // { dg-message "previous declaration" } template<int> void foo() {} // { dg-error "redeclared" } diff --git a/gcc/testsuite/g++.dg/tls/diag-3.C b/gcc/testsuite/g++.dg/tls/diag-3.C index ea5158b..0604617 100644 --- a/gcc/testsuite/g++.dg/tls/diag-3.C +++ b/gcc/testsuite/g++.dg/tls/diag-3.C @@ -1,10 +1,10 @@ // Report invalid extern and __thread combinations. // { dg-require-effective-target tls } -extern int j; // { dg-error "previously declared here" } +extern int j; // { dg-message "previously declared here" } __thread int j; // { dg-error "follows non-thread-local" } -extern __thread int i; // { dg-error "previously declared here" } +extern __thread int i; // { dg-message "previously declared here" } int i; // { dg-error "follows thread-local" } extern __thread int k; // This is fine. diff --git a/gcc/testsuite/g++.dg/warn/Wredundant-decls-spec.C b/gcc/testsuite/g++.dg/warn/Wredundant-decls-spec.C index b5c790f..3a9b019 100644 --- a/gcc/testsuite/g++.dg/warn/Wredundant-decls-spec.C +++ b/gcc/testsuite/g++.dg/warn/Wredundant-decls-spec.C @@ -8,5 +8,5 @@ template <typename T> struct S template<> void S<int>::foo(); -template<> void S<double>::foo(); // { dg-warning "previous declaration" } +template<> void S<double>::foo(); // { dg-message "previous declaration" } template<> void S<double>::foo(); // { dg-warning "redundant redeclaration" } diff --git a/gcc/testsuite/g++.old-deja/g++.benjamin/typedef01.C b/gcc/testsuite/g++.old-deja/g++.benjamin/typedef01.C index d5ed39a..af65162 100644 --- a/gcc/testsuite/g++.old-deja/g++.benjamin/typedef01.C +++ b/gcc/testsuite/g++.old-deja/g++.benjamin/typedef01.C @@ -16,7 +16,7 @@ typedef int I; typedef I I; //p3--cannot redefine to a different type in a given scope -class complex2 { /* ... */ };// { dg-error "" } .* +class complex2 { /* ... */ };// { dg-message "" } .* typedef int complex2;// { dg-error "" } .* typedef int complex3;// { dg-message "" } .* class complex3 { /* ... */ };// { dg-error "" } .* diff --git a/gcc/testsuite/g++.old-deja/g++.benjamin/warn02.C b/gcc/testsuite/g++.old-deja/g++.benjamin/warn02.C index 248e1ed..a3d2374 100644 --- a/gcc/testsuite/g++.old-deja/g++.benjamin/warn02.C +++ b/gcc/testsuite/g++.old-deja/g++.benjamin/warn02.C @@ -44,11 +44,5 @@ public: int b; }; +extern int foo3(const char *); // { dg-message "" } extern int foo3(const char *); // { dg-warning "" } -extern int foo3(const char *); // { dg-warning "" } - - - - - - diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/crash16.C b/gcc/testsuite/g++.old-deja/g++.brendan/crash16.C index 674fc4f..5e6acc8 100644 --- a/gcc/testsuite/g++.old-deja/g++.brendan/crash16.C +++ b/gcc/testsuite/g++.old-deja/g++.brendan/crash16.C @@ -5,7 +5,7 @@ class Graph { // { dg-error "1:new types|1: note: \\(perhaps" } public: unsigned char N; - Graph(void) {} // { dg-error "7:'Graph" } + Graph(void) {} // { dg-message "7:'Graph" } } Graph::Graph(void) // { dg-error "18:return type|1: error: redefinition" } diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/crash18.C b/gcc/testsuite/g++.old-deja/g++.brendan/crash18.C index 119ba46..3119f02 100644 --- a/gcc/testsuite/g++.old-deja/g++.brendan/crash18.C +++ b/gcc/testsuite/g++.old-deja/g++.brendan/crash18.C @@ -7,7 +7,7 @@ public: Pix(const Pix&); // Friend functions so that v == x works as does x == v works - friend int operator==(void *v, const Pix& x) // { dg-error "previously" } + friend int operator==(void *v, const Pix& x) // { dg-message "previously" } { return v == index; } // { dg-error "from this location" } // ??? should be operator!= friend int operator==(void *v, const Pix& x) // { dg-error "redefinition" } diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/err-msg4.C b/gcc/testsuite/g++.old-deja/g++.brendan/err-msg4.C index 2f4bc42..d1d8444 100644 --- a/gcc/testsuite/g++.old-deja/g++.brendan/err-msg4.C +++ b/gcc/testsuite/g++.old-deja/g++.brendan/err-msg4.C @@ -2,8 +2,8 @@ // GROUPS passed error-messages class X { public: - static int x;// { dg-error "" } previous.* - static int y;// { dg-error "" } previous.* + static int x;// { dg-message "" } previous.* + static int y;// { dg-message "" } previous.* }; unsigned X::x;// { dg-error "" } conflict.* diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/redecl1.C b/gcc/testsuite/g++.old-deja/g++.brendan/redecl1.C index 0e01f2b..1edd548 100644 --- a/gcc/testsuite/g++.old-deja/g++.brendan/redecl1.C +++ b/gcc/testsuite/g++.old-deja/g++.brendan/redecl1.C @@ -1,5 +1,5 @@ // { dg-do assemble } // GROUPS passed redeclaration -inline int min(int x, int y) {return x < y ? x : y;} /* 235 */// { dg-error "" } .* +inline int min(int x, int y) {return x < y ? x : y;} /* 235 */// { dg-message "" } .* int min(int a, int b); inline int min(int a, int b) {return (a < b)?a:b;}// { dg-error "" } .* diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/static3.C b/gcc/testsuite/g++.old-deja/g++.brendan/static3.C index c0ee011..7c43231 100644 --- a/gcc/testsuite/g++.old-deja/g++.brendan/static3.C +++ b/gcc/testsuite/g++.old-deja/g++.brendan/static3.C @@ -3,7 +3,7 @@ class foo{ public: static void bar( int i ){ value = i; } - static int value;// { dg-error "" } .* + static int value;// { dg-message "" } .* }; const int foo::value = 0; // should be an error.// { dg-error "" } .* diff --git a/gcc/testsuite/g++.old-deja/g++.bugs/900127_02.C b/gcc/testsuite/g++.old-deja/g++.bugs/900127_02.C index 12ae64a..c74baa9 100644 --- a/gcc/testsuite/g++.old-deja/g++.bugs/900127_02.C +++ b/gcc/testsuite/g++.old-deja/g++.bugs/900127_02.C @@ -16,10 +16,10 @@ // keywords: name spaces, overloading -int global0; // { dg-error "" } +int global0; // { dg-message "" } int global0 (); // { dg-error "" } -int global1 (); // { dg-error "" } xref for below +int global1 (); // { dg-message "" } xref for below int global1; // { dg-error "" } caught struct struct_0 { @@ -34,13 +34,13 @@ struct struct_1 { void function_0 () { - int function_0_local; // { dg-error "" } + int function_0_local; // { dg-message "" } extern int function_0_local (); // { dg-error "" } } void function_1 () { - int function_1_local (); // { dg-error "" } + int function_1_local (); // { dg-message "" } extern int function_1_local; // { dg-error "" } } diff --git a/gcc/testsuite/g++.old-deja/g++.jason/binding.C b/gcc/testsuite/g++.old-deja/g++.jason/binding.C index 1f297b7..3321cec 100644 --- a/gcc/testsuite/g++.old-deja/g++.jason/binding.C +++ b/gcc/testsuite/g++.old-deja/g++.jason/binding.C @@ -6,7 +6,7 @@ struct T { ~T(); }; int main() { foo: - T t; // { dg-error "" } redeclared + T t; // { dg-message "" } redeclared bar: T t; // { dg-error "" } redeclaration } diff --git a/gcc/testsuite/g++.old-deja/g++.jason/crash4.C b/gcc/testsuite/g++.old-deja/g++.jason/crash4.C index 00ba0cc..30c563b 100644 --- a/gcc/testsuite/g++.old-deja/g++.jason/crash4.C +++ b/gcc/testsuite/g++.old-deja/g++.jason/crash4.C @@ -16,7 +16,7 @@ public: }; template <class T> -const ccObjectInfo& cc_Array<T>::repInvariant(int) const // { dg-error "previously declared" } +const ccObjectInfo& cc_Array<T>::repInvariant(int) const // { dg-message "previously declared" } { return *this /* *this is required here */; } template <class T> diff --git a/gcc/testsuite/g++.old-deja/g++.jason/crash7.C b/gcc/testsuite/g++.old-deja/g++.jason/crash7.C index 95c7c2f..f17c402 100644 --- a/gcc/testsuite/g++.old-deja/g++.jason/crash7.C +++ b/gcc/testsuite/g++.old-deja/g++.jason/crash7.C @@ -1,6 +1,6 @@ // { dg-do assemble } // Bug: g++ can't deal. -typedef unsigned size_t; // { dg-error "" } previous declaration +typedef unsigned size_t; // { dg-message "" } previous declaration typedef unsigned long size_t; // { dg-error "" } redefining size_t void f (size_t); // causes compiler segfault - diff --git a/gcc/testsuite/g++.old-deja/g++.jason/lineno.C b/gcc/testsuite/g++.old-deja/g++.jason/lineno.C index bd5a393..4ef9208 100644 --- a/gcc/testsuite/g++.old-deja/g++.jason/lineno.C +++ b/gcc/testsuite/g++.old-deja/g++.jason/lineno.C @@ -1,6 +1,6 @@ // { dg-do assemble } // Bug; g++ binds a function definition to the line number of a later decl. -void foo () { } // { dg-error "" } redeclared +void foo () { } // { dg-message "" } redeclared void foo (); // { dg-bogus "" } invalid binding void foo () { } // { dg-error "" } redeclared diff --git a/gcc/testsuite/g++.old-deja/g++.jason/scoping7.C b/gcc/testsuite/g++.old-deja/g++.jason/scoping7.C index 41859aa..245c8fa 100644 --- a/gcc/testsuite/g++.old-deja/g++.jason/scoping7.C +++ b/gcc/testsuite/g++.old-deja/g++.jason/scoping7.C @@ -2,5 +2,5 @@ // Bug: g++ doesn't flag name collisions between types and non-types as // errors. It shouldn't for class names, but it should for typedefs. -int bar; // { dg-error "" } +int bar; // { dg-message "" } typedef int bar; // { dg-error "" } diff --git a/gcc/testsuite/g++.old-deja/g++.mike/misc3.C b/gcc/testsuite/g++.old-deja/g++.mike/misc3.C index 560f0c1..f633873 100644 --- a/gcc/testsuite/g++.old-deja/g++.mike/misc3.C +++ b/gcc/testsuite/g++.old-deja/g++.mike/misc3.C @@ -1,4 +1,4 @@ // { dg-do assemble } // GROUPS uncaught -int a;// { dg-error "" } .* +int a;// { dg-message "" } .* int a;// { dg-error "" } .* diff --git a/gcc/testsuite/g++.old-deja/g++.mike/net44.C b/gcc/testsuite/g++.old-deja/g++.mike/net44.C index bc45b48..226df2d 100644 --- a/gcc/testsuite/g++.old-deja/g++.mike/net44.C +++ b/gcc/testsuite/g++.old-deja/g++.mike/net44.C @@ -1,7 +1,7 @@ // { dg-do assemble } // Make sure we don't dump core -enum request { q, w, e}; // { dg-error "" } +enum request { q, w, e}; // { dg-message "" } class request { // { dg-error "" } public: diff --git a/gcc/testsuite/g++.old-deja/g++.mike/ns3.C b/gcc/testsuite/g++.old-deja/g++.mike/ns3.C index eb40fe4..b39a1d7 100644 --- a/gcc/testsuite/g++.old-deja/g++.mike/ns3.C +++ b/gcc/testsuite/g++.old-deja/g++.mike/ns3.C @@ -1,5 +1,5 @@ // { dg-do assemble } -int i; // { dg-error "" } +int i; // { dg-message "" } namespace i { // { dg-error "" } } diff --git a/gcc/testsuite/g++.old-deja/g++.ns/alias4.C b/gcc/testsuite/g++.old-deja/g++.ns/alias4.C index 5bff439..2d9dd4a 100644 --- a/gcc/testsuite/g++.old-deja/g++.ns/alias4.C +++ b/gcc/testsuite/g++.old-deja/g++.ns/alias4.C @@ -7,7 +7,7 @@ namespace D { // { dg-error "" } reopening namespace with alias void f(); } -void C::f(){} // { dg-error "" } previous definition +void C::f(){} // { dg-message "" } previous definition void D::f(){} // { dg-error "" } redefinition diff --git a/gcc/testsuite/g++.old-deja/g++.ns/ns11.C b/gcc/testsuite/g++.old-deja/g++.ns/ns11.C index 2dc0344..3067bdf 100644 --- a/gcc/testsuite/g++.old-deja/g++.ns/ns11.C +++ b/gcc/testsuite/g++.old-deja/g++.ns/ns11.C @@ -5,7 +5,7 @@ namespace A{ void f(int); void f(int,int); - int i; // { dg-error "" } .* + int i; // { dg-message "" } .* } void A::f(){} // { dg-error "" } should have been declared before diff --git a/gcc/testsuite/g++.old-deja/g++.other/crash23.C b/gcc/testsuite/g++.old-deja/g++.other/crash23.C index 1324902..72f94cb 100644 --- a/gcc/testsuite/g++.old-deja/g++.other/crash23.C +++ b/gcc/testsuite/g++.old-deja/g++.other/crash23.C @@ -2,6 +2,6 @@ // Origin: Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at> class T; -inline void operator<(T&, T&) { } // { dg-error "" } previous definition +inline void operator<(T&, T&) { } // { dg-message "" } previous definition inline void operator<(T&, T&) { } // { dg-error "" } duplicate definition diff --git a/gcc/testsuite/g++.old-deja/g++.other/decl8.C b/gcc/testsuite/g++.old-deja/g++.other/decl8.C index 705fc6c..ebcc064 100644 --- a/gcc/testsuite/g++.old-deja/g++.other/decl8.C +++ b/gcc/testsuite/g++.old-deja/g++.other/decl8.C @@ -3,7 +3,7 @@ void foo(void) { - extern int i; // { dg-error "" } previous declaration + extern int i; // { dg-message "" } previous declaration extern double i; // { dg-error "" } conflicting type extern int j; extern int j; diff --git a/gcc/testsuite/g++.old-deja/g++.other/linkage3.C b/gcc/testsuite/g++.old-deja/g++.other/linkage3.C index 8ddff82..5e01c1d 100644 --- a/gcc/testsuite/g++.old-deja/g++.other/linkage3.C +++ b/gcc/testsuite/g++.old-deja/g++.other/linkage3.C @@ -1,5 +1,5 @@ // { dg-do assemble } // Origin: Mark Mitchell <mark@codesourcery.com> -extern "C" void f (); // { dg-error "" } previous declaration +extern "C" void f (); // { dg-message "" } previous declaration static void f () {} // { dg-error "" } extern redeclared static diff --git a/gcc/testsuite/g++.old-deja/g++.other/typeck1.C b/gcc/testsuite/g++.old-deja/g++.other/typeck1.C index 574fd7e..1dce273 100644 --- a/gcc/testsuite/g++.old-deja/g++.other/typeck1.C +++ b/gcc/testsuite/g++.old-deja/g++.other/typeck1.C @@ -4,7 +4,7 @@ extern int a[][]; // { dg-error "" } invalid multidimensional array extern int b[7][]; // { dg-error "" } invalid multidimensional array extern int c[][7]; // OK -extern int (*i)[]; // { dg-error "" } previous declaration +extern int (*i)[]; // { dg-message "" } previous declaration extern int (*i)[7]; // { dg-error "" } conflicting types for `i' extern int m[]; diff --git a/gcc/testsuite/g++.old-deja/g++.other/typedef5.C b/gcc/testsuite/g++.old-deja/g++.other/typedef5.C index f9e7147..0984550 100644 --- a/gcc/testsuite/g++.old-deja/g++.other/typedef5.C +++ b/gcc/testsuite/g++.old-deja/g++.other/typedef5.C @@ -10,7 +10,7 @@ typedef int t; typedef t* u; typedef u v; typedef v* (*w)(t const); // this is ok -typedef v* (*w)(t); // { dg-error "" } covers message `previously declared here' +typedef v* (*w)(t); // { dg-message "" } covers message `previously declared here' typedef v* (*const w)(t); // { dg-error "" } invalid redeclaration typedef v const* (*w)(t); // { dg-error "" } invalid redeclaration typedef v* const (*w)(t); // { dg-error "" } invalid redeclaration diff --git a/gcc/testsuite/g++.old-deja/g++.pt/explicit34.C b/gcc/testsuite/g++.old-deja/g++.pt/explicit34.C index ea32cf6..54029eb 100644 --- a/gcc/testsuite/g++.old-deja/g++.pt/explicit34.C +++ b/gcc/testsuite/g++.old-deja/g++.pt/explicit34.C @@ -5,7 +5,7 @@ template <class T> void foo(T t); template <> -void foo(int) {}; // { dg-error "6:previously declared here" } +void foo(int) {}; // { dg-message "6:previously declared here" } template <> void foo<int>(int) {} // { dg-error "6:redefinition" } diff --git a/gcc/testsuite/g++.old-deja/g++.pt/friend36.C b/gcc/testsuite/g++.old-deja/g++.pt/friend36.C index f5cb8d4..f6f261b 100644 --- a/gcc/testsuite/g++.old-deja/g++.pt/friend36.C +++ b/gcc/testsuite/g++.old-deja/g++.pt/friend36.C @@ -1,7 +1,7 @@ // { dg-do assemble } template <class T> -void f(T) {} // { dg-error "previously" } +void f(T) {} // { dg-message "previously" } template <class U> struct S { diff --git a/gcc/testsuite/obj-c++.dg/method-8.mm b/gcc/testsuite/obj-c++.dg/method-8.mm index 9857c63..cde1bc2 100644 --- a/gcc/testsuite/obj-c++.dg/method-8.mm +++ b/gcc/testsuite/obj-c++.dg/method-8.mm @@ -16,7 +16,7 @@ @end @implementation class3 -- (int) meth1 { return 0; } /* { dg-error "previously defined here" } */ +- (int) meth1 { return 0; } /* { dg-message "previously defined here" } */ - (int) meth1 { return 0; } /* { dg-error "redefinition of" } */ @end @@ -25,6 +25,6 @@ @end @implementation class4 -+ (void) meth1 {} /* { dg-error "previously defined here" } */ ++ (void) meth1 {} /* { dg-message "previously defined here" } */ + (void) meth1 {} /* { dg-error "redefinition of" } */ @end diff --git a/gcc/testsuite/obj-c++.dg/tls/diag-3.mm b/gcc/testsuite/obj-c++.dg/tls/diag-3.mm index 0a597b2..22c2395 100644 --- a/gcc/testsuite/obj-c++.dg/tls/diag-3.mm +++ b/gcc/testsuite/obj-c++.dg/tls/diag-3.mm @@ -1,10 +1,10 @@ /* Report invalid extern and __thread combinations. */ /* { dg-require-effective-target tls } */ -extern int j; /* { dg-error "previously declared here" } */ +extern int j; /* { dg-message "previously declared here" } */ __thread int j; /* { dg-error "follows non-thread-local" } */ -extern __thread int i; /* { dg-error "previously declared here" } */ +extern __thread int i; /* { dg-message "previously declared here" } */ int i; /* { dg-error "follows thread-local" } */ extern __thread int k; /* This is fine. */ |