From: Jason Merrill Date: Fri, 10 Jun 2011 03:56:17 +0000 (-0400) Subject: prune.exp: Prune "note"s. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0dbe3777353ae62281f913cfc5df518d1dce98c7;p=gcc.git prune.exp: Prune "note"s. * lib/prune.exp: Prune "note"s. * g++.dg/uninit-pred-3_b.C: Remove dg-excess-errors. * g++.dg/ext/injected-ttp.C: Specify -std=c++98. * g++.dg/template/dependent-expr3.C: Likewise. * g++.dg/parse/template7.C: Likewise. * g++.old-deja/g++.bugs/900119_01.C: Likewise. * g++.old-deja/g++.jason/rfg10.C: Likewise. * g++.old-deja/g++.pt/friend38.C: Likewise. * g++.old-deja/g++.pt/crash32.C: Likewise. * g++.old-deja/g++.other/init4.C: Likewise. * g++.old-deja/g++.other/friend8.C: Likewise. * g++.dg/ext/complex7.C: Adjust expected output. * g++.dg/diagnostic/method1.C: Likewise. * g++.dg/parse/parameter-declaration-2.C: Likewise. * g++.dg/parse/crash33.C: Likewise. * g++.dg/other/warning1.C: Likewise. * g++.dg/init/pr29571.C: Likewise. * g++.dg/warn/overflow-warn-1.C: Likewise. * g++.dg/warn/overflow-warn-3.C: Likewise. * g++.dg/warn/overflow-warn-4.C: Likewise. * g++.old-deja/g++.oliva/template1.C: Likewise. From-SVN: r174886 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 54b17c2e964..d93c01a2a4e 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,5 +1,29 @@ 2011-06-09 Jason Merrill + * lib/prune.exp: Prune "note"s. + * g++.dg/uninit-pred-3_b.C: Remove dg-excess-errors. + + * g++.dg/ext/injected-ttp.C: Specify -std=c++98. + * g++.dg/template/dependent-expr3.C: Likewise. + * g++.dg/parse/template7.C: Likewise. + * g++.old-deja/g++.bugs/900119_01.C: Likewise. + * g++.old-deja/g++.jason/rfg10.C: Likewise. + * g++.old-deja/g++.pt/friend38.C: Likewise. + * g++.old-deja/g++.pt/crash32.C: Likewise. + * g++.old-deja/g++.other/init4.C: Likewise. + * g++.old-deja/g++.other/friend8.C: Likewise. + + * g++.dg/ext/complex7.C: Adjust expected output. + * g++.dg/diagnostic/method1.C: Likewise. + * g++.dg/parse/parameter-declaration-2.C: Likewise. + * g++.dg/parse/crash33.C: Likewise. + * g++.dg/other/warning1.C: Likewise. + * g++.dg/init/pr29571.C: Likewise. + * g++.dg/warn/overflow-warn-1.C: Likewise. + * g++.dg/warn/overflow-warn-3.C: Likewise. + * g++.dg/warn/overflow-warn-4.C: Likewise. + * g++.old-deja/g++.oliva/template1.C: Likewise. + * g++.dg/cpp0x/regress/error-recovery1.C: Adjust. * g++.dg/parse/template7.C: Adjust. diff --git a/gcc/testsuite/g++.dg/diagnostic/method1.C b/gcc/testsuite/g++.dg/diagnostic/method1.C index 8e1225d0722..4a781047ef8 100644 --- a/gcc/testsuite/g++.dg/diagnostic/method1.C +++ b/gcc/testsuite/g++.dg/diagnostic/method1.C @@ -18,3 +18,5 @@ baz () { bar (); } + +// { dg-prune-output "without object" } diff --git a/gcc/testsuite/g++.dg/ext/complex7.C b/gcc/testsuite/g++.dg/ext/complex7.C index 9d5463f94dc..5b3eead1810 100644 --- a/gcc/testsuite/g++.dg/ext/complex7.C +++ b/gcc/testsuite/g++.dg/ext/complex7.C @@ -4,3 +4,5 @@ class A { static const _Complex double x = 1.0 + 2.0i; }; + +// { dg-prune-output "constexpr. needed" } diff --git a/gcc/testsuite/g++.dg/ext/injected-ttp.C b/gcc/testsuite/g++.dg/ext/injected-ttp.C index 405bee88cdf..5ef4a4ec4f1 100644 --- a/gcc/testsuite/g++.dg/ext/injected-ttp.C +++ b/gcc/testsuite/g++.dg/ext/injected-ttp.C @@ -1,7 +1,7 @@ // Test for doing the right thing with injected-class-name used as template // type argument. This is an extension from DR 176. -// { dg-options "-pedantic" } +// { dg-options "-pedantic -std=c++98" } template struct A { }; diff --git a/gcc/testsuite/g++.dg/init/pr29571.C b/gcc/testsuite/g++.dg/init/pr29571.C index 9e8e6093ef2..c9bfa28862e 100644 --- a/gcc/testsuite/g++.dg/init/pr29571.C +++ b/gcc/testsuite/g++.dg/init/pr29571.C @@ -3,6 +3,6 @@ struct A { static const int i = 0/0 + ""; // { dg-warning "division by zero" } - // { dg-error "field initializer is not constant" "" { target *-*-* } 5 } + // { dg-error "field initializer is not constant|not a constant-expression" "" { target *-*-* } 5 } static const int j = int(i); }; diff --git a/gcc/testsuite/g++.dg/other/warning1.C b/gcc/testsuite/g++.dg/other/warning1.C index 77653a1df13..c65ae0ff6ef 100644 --- a/gcc/testsuite/g++.dg/other/warning1.C +++ b/gcc/testsuite/g++.dg/other/warning1.C @@ -7,8 +7,8 @@ extern "C" int printf(const char *, ...); struct S { - static const float inf = 1.0f / 0.0f; // { dg-warning "1.0|float|initialization" } - static const float nan = 0.0f / 0.0f; // { dg-warning "0.0|float|initialization" } + static const float inf = 1.0f / 0.0f; // { dg-warning "1.0|float|initializ" } + static const float nan = 0.0f / 0.0f; // { dg-warning "0.0|float|initializ" } }; int main() diff --git a/gcc/testsuite/g++.dg/parse/crash33.C b/gcc/testsuite/g++.dg/parse/crash33.C index 2ab84df46d3..5ccb6529c6e 100644 --- a/gcc/testsuite/g++.dg/parse/crash33.C +++ b/gcc/testsuite/g++.dg/parse/crash33.C @@ -4,5 +4,8 @@ template void foo() [ - throw; // { dg-error "expected" } -} // { dg-error "expected" } + throw; +} + +// { dg-prune-output "expected" } +// { dg-prune-output "array bound" } diff --git a/gcc/testsuite/g++.dg/parse/parameter-declaration-2.C b/gcc/testsuite/g++.dg/parse/parameter-declaration-2.C index 7a9a24fb752..6116630433f 100644 --- a/gcc/testsuite/g++.dg/parse/parameter-declaration-2.C +++ b/gcc/testsuite/g++.dg/parse/parameter-declaration-2.C @@ -1 +1,2 @@ void f (int i, int p[i]); // { dg-error "use of parameter .i. outside function body" } +// { dg-prune-output "array bound" } diff --git a/gcc/testsuite/g++.dg/parse/template7.C b/gcc/testsuite/g++.dg/parse/template7.C index d7dfef7c11c..930e259fe1e 100644 --- a/gcc/testsuite/g++.dg/parse/template7.C +++ b/gcc/testsuite/g++.dg/parse/template7.C @@ -1,3 +1,5 @@ +// { dg-options -std=c++98 } + template void f(); // { dg-message "note" } diff --git a/gcc/testsuite/g++.dg/template/dependent-expr3.C b/gcc/testsuite/g++.dg/template/dependent-expr3.C index 97fddbdd8d4..bf14c49b42b 100644 --- a/gcc/testsuite/g++.dg/template/dependent-expr3.C +++ b/gcc/testsuite/g++.dg/template/dependent-expr3.C @@ -1,3 +1,4 @@ +// { dg-options -std=c++98 } // { dg-do compile } // Origin: jbrandmeyer at users dot sourceforge dot net // PR c++/12573: COMPONENT_REFs must be inspected for dependness. diff --git a/gcc/testsuite/g++.dg/uninit-pred-3_b.C b/gcc/testsuite/g++.dg/uninit-pred-3_b.C index cfe2113bb6e..a66e04becb2 100644 --- a/gcc/testsuite/g++.dg/uninit-pred-3_b.C +++ b/gcc/testsuite/g++.dg/uninit-pred-3_b.C @@ -65,7 +65,7 @@ class M { void P (int64 t) { - int cc; /* { dg-excess-errors "note: 'cc' was declared here" } */ + int cc; if (!GetC (&cc)) return; diff --git a/gcc/testsuite/g++.dg/warn/overflow-warn-1.C b/gcc/testsuite/g++.dg/warn/overflow-warn-1.C index 22c512a4f8f..7cd76e74c7a 100644 --- a/gcc/testsuite/g++.dg/warn/overflow-warn-1.C +++ b/gcc/testsuite/g++.dg/warn/overflow-warn-1.C @@ -13,7 +13,7 @@ enum e { in the standard). */ E2 = 2 || 1 / 0, /* { dg-bogus "warning: division by zero" "" { xfail *-*-* } 14 } */ E3 = 1 / 0, /* { dg-warning "division by zero" } */ - /* { dg-error "enumerator value for 'E3' is not an integer constant|not a constant expression" "enum error" { target *-*-* } 15 } */ + /* { dg-error "enumerator value for 'E3' is not an integer constant|not a constant.expression" "enum error" { target *-*-* } 15 } */ /* But as in DR#031, the 1/0 in an evaluated subexpression means the whole expression violates the constraints. */ E4 = 0 * (1 / 0), /* { dg-warning "division by zero" } */ diff --git a/gcc/testsuite/g++.dg/warn/overflow-warn-3.C b/gcc/testsuite/g++.dg/warn/overflow-warn-3.C index d88c87a5398..73c0e006f56 100644 --- a/gcc/testsuite/g++.dg/warn/overflow-warn-3.C +++ b/gcc/testsuite/g++.dg/warn/overflow-warn-3.C @@ -13,7 +13,7 @@ enum e { in the standard). */ E2 = 2 || 1 / 0, /* { dg-bogus "warning: division by zero" "" { xfail *-*-* } 14 } */ E3 = 1 / 0, /* { dg-warning "division by zero" } */ - /* { dg-error "enumerator value for 'E3' is not an integer constant|not a constant expression" "enum error" { target *-*-* } 15 } */ + /* { dg-error "enumerator value for 'E3' is not an integer constant|not a constant.expression" "enum error" { target *-*-* } 15 } */ /* But as in DR#031, the 1/0 in an evaluated subexpression means the whole expression violates the constraints. */ E4 = 0 * (1 / 0), /* { dg-warning "division by zero" } */ diff --git a/gcc/testsuite/g++.dg/warn/overflow-warn-4.C b/gcc/testsuite/g++.dg/warn/overflow-warn-4.C index 374d29428a8..24b3959a034 100644 --- a/gcc/testsuite/g++.dg/warn/overflow-warn-4.C +++ b/gcc/testsuite/g++.dg/warn/overflow-warn-4.C @@ -13,7 +13,7 @@ enum e { in the standard). */ E2 = 2 || 1 / 0, /* { dg-bogus "warning: division by zero" "" { xfail *-*-* } } */ E3 = 1 / 0, /* { dg-warning "division by zero" } */ - /* { dg-error "enumerator value for 'E3' is not an integer constant|not a constant expression" "enum error" { target *-*-* } 15 } */ + /* { dg-error "enumerator value for 'E3' is not an integer constant|not a constant.expression" "enum error" { target *-*-* } 15 } */ /* But as in DR#031, the 1/0 in an evaluated subexpression means the whole expression violates the constraints. */ E4 = 0 * (1 / 0), /* { dg-warning "division by zero" } */ diff --git a/gcc/testsuite/g++.old-deja/g++.bugs/900119_01.C b/gcc/testsuite/g++.old-deja/g++.bugs/900119_01.C index ace4e4b7ac1..0d181c7eeb8 100644 --- a/gcc/testsuite/g++.old-deja/g++.bugs/900119_01.C +++ b/gcc/testsuite/g++.old-deja/g++.bugs/900119_01.C @@ -1,3 +1,4 @@ +// { dg-options "-pedantic-errors -std=c++98" } // { dg-do assemble } // g++ 1.36.1 bug 900119_01 @@ -8,7 +9,7 @@ // keywords: member declaration, member initialization -// { dg-prune-output "non-static data member initializers" } +// { dg-prune-output "is a static data member" } int global_int; @@ -18,7 +19,7 @@ public: static int class0_member_1 = 99; /* { dg-error "" } */ int &class0_member_2 = global_int; /* { dg-error "" } */ - class0 () : class0_member_2 (global_int) { } /* { dg-error "" } */ + class0 () : class0_member_2 (global_int) { } }; @@ -27,7 +28,7 @@ struct struct0 { static int struct0_member_1 = 99; /* { dg-error "" } */ int &struct0_member_2 = global_int; /* { dg-error "" } */ - struct0 () : struct0_member_2 (global_int) { } /* { dg-error "" } */ + struct0 () : struct0_member_2 (global_int) { } }; // g++ does not allow unions to have more than one member with an initializer @@ -43,7 +44,7 @@ union union1 { union union2 { int &union2_member_0 = global_int; /* { dg-error "" } */ - union2 () : union2_member_0 (global_int) { } /* { dg-error "" } */ + union2 () : union2_member_0 (global_int) { } }; int main () { return 0; } diff --git a/gcc/testsuite/g++.old-deja/g++.jason/rfg10.C b/gcc/testsuite/g++.old-deja/g++.jason/rfg10.C index 58af19c3364..8769f5afc46 100644 --- a/gcc/testsuite/g++.old-deja/g++.jason/rfg10.C +++ b/gcc/testsuite/g++.old-deja/g++.jason/rfg10.C @@ -1,5 +1,5 @@ // { dg-do assemble } -// { dg-options "-pedantic-errors" } +// { dg-options "-pedantic-errors -std=c++98" } // Bug: g++ doesn't notice the overflow in the enum values. #include diff --git a/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog b/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog deleted file mode 100644 index 995ac91835a..00000000000 --- a/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog +++ /dev/null @@ -1,127 +0,0 @@ -2005-04-03 Alexandre Oliva - - PR c++/19199 - * expr2.C: Fixed. - -2003-06-04 J"orn Rennecke - - * template1.C (bar): Remove xfail marker. - -2002-07-06 Alexandre Oliva - - * linkage1.C, linkage1-main.cc: New test. - -2001-02-15 Alexandre Oliva - - * friend1.C: New test. - -2000-05-28 Alexandre Oliva - - * expr2.C: New test. - -2000-04-19 Alexandre Oliva - - * stkalign.C: New test. - -1999-12-22 Alexandre Oliva - - * nameret2.C: New test. - - * nameret1.C: New test. - - * template10.C: New test. - -1999-11-21 Alexandre Oliva - - * delete2.C, delete3.C, delete4.C, delete5.C: New tests. - -1999-11-19 Alexandre Oliva - - * template7.C: Crash test passes, bug error is now bogus. - -1999-11-11 Alexandre Oliva - - * template9.C: New test. - -1999-09-18 Alexandre Oliva - - * overload1.C: New test. - - * inline1.C: New test. - -1999-08-25 Alexandre Oliva - - * thunk1.C: New test. - -1999-08-06 Alexandre Oliva - - * dwarf2.C, dwarf3.C: Added XFAIL for Solaris/x86. Removed - -gdwarf. - * dwarf1.C: Removed -gdwarf. - -1999-08-05 Alexandre Oliva - - * new1.C, template8.C: Removed XFAIL. - * template3.C: Re-introduced XFAIL. :-( - -1999-08-03 Alexandre Oliva - - * ext1.C: New test. - - * dwarf1.C, dwarf2.C, dwarf3.C: New tests. - -1999-07-20 Alexandre Oliva - - * template8.C, typeof1.C: New test. - -1999-07-17 Alexandre Oliva - - * template6.C, delete1.C, template7.C: New test. - -1999-07-13 Alexandre Oliva - - * template5.C: New test. - - * template4.C: New test. - - * expr1.C: New test. - - * partspec1.C: New test. - -1999-07-05 Alexandre Oliva - - * typename1.C, typename2.C: New tests. - - * template3.C: Fixed. - - * ns3.C: New test. - -1999-07-03 Alexandre Oliva - - * ctor1.C: New test. - - * template3.C: New test. - -1999-07-02 Alexandre Oliva - - * ns1.C: Typo. - * ns2.C: New test. - - * template2.C: New test. - - * ns1.C: New test. - -1999-07-01 Alexandre Oliva - - * new1.C: New test. - - * partord1.C: New test. - - * template1.C: New test. - - -Copyright (C) 1999, 2000, 2001, 2002, 2003, 2005 Free Software Foundation, Inc. - -Copying and distribution of this file, with or without modification, -are permitted in any medium without royalty provided the copyright -notice and this notice are preserved. diff --git a/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog-2005 b/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog-2005 new file mode 100644 index 00000000000..995ac91835a --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.oliva/ChangeLog-2005 @@ -0,0 +1,127 @@ +2005-04-03 Alexandre Oliva + + PR c++/19199 + * expr2.C: Fixed. + +2003-06-04 J"orn Rennecke + + * template1.C (bar): Remove xfail marker. + +2002-07-06 Alexandre Oliva + + * linkage1.C, linkage1-main.cc: New test. + +2001-02-15 Alexandre Oliva + + * friend1.C: New test. + +2000-05-28 Alexandre Oliva + + * expr2.C: New test. + +2000-04-19 Alexandre Oliva + + * stkalign.C: New test. + +1999-12-22 Alexandre Oliva + + * nameret2.C: New test. + + * nameret1.C: New test. + + * template10.C: New test. + +1999-11-21 Alexandre Oliva + + * delete2.C, delete3.C, delete4.C, delete5.C: New tests. + +1999-11-19 Alexandre Oliva + + * template7.C: Crash test passes, bug error is now bogus. + +1999-11-11 Alexandre Oliva + + * template9.C: New test. + +1999-09-18 Alexandre Oliva + + * overload1.C: New test. + + * inline1.C: New test. + +1999-08-25 Alexandre Oliva + + * thunk1.C: New test. + +1999-08-06 Alexandre Oliva + + * dwarf2.C, dwarf3.C: Added XFAIL for Solaris/x86. Removed + -gdwarf. + * dwarf1.C: Removed -gdwarf. + +1999-08-05 Alexandre Oliva + + * new1.C, template8.C: Removed XFAIL. + * template3.C: Re-introduced XFAIL. :-( + +1999-08-03 Alexandre Oliva + + * ext1.C: New test. + + * dwarf1.C, dwarf2.C, dwarf3.C: New tests. + +1999-07-20 Alexandre Oliva + + * template8.C, typeof1.C: New test. + +1999-07-17 Alexandre Oliva + + * template6.C, delete1.C, template7.C: New test. + +1999-07-13 Alexandre Oliva + + * template5.C: New test. + + * template4.C: New test. + + * expr1.C: New test. + + * partspec1.C: New test. + +1999-07-05 Alexandre Oliva + + * typename1.C, typename2.C: New tests. + + * template3.C: Fixed. + + * ns3.C: New test. + +1999-07-03 Alexandre Oliva + + * ctor1.C: New test. + + * template3.C: New test. + +1999-07-02 Alexandre Oliva + + * ns1.C: Typo. + * ns2.C: New test. + + * template2.C: New test. + + * ns1.C: New test. + +1999-07-01 Alexandre Oliva + + * new1.C: New test. + + * partord1.C: New test. + + * template1.C: New test. + + +Copyright (C) 1999, 2000, 2001, 2002, 2003, 2005 Free Software Foundation, Inc. + +Copying and distribution of this file, with or without modification, +are permitted in any medium without royalty provided the copyright +notice and this notice are preserved. diff --git a/gcc/testsuite/g++.old-deja/g++.oliva/template1.C b/gcc/testsuite/g++.old-deja/g++.oliva/template1.C index ce394961804..908a06990a2 100644 --- a/gcc/testsuite/g++.old-deja/g++.oliva/template1.C +++ b/gcc/testsuite/g++.old-deja/g++.oliva/template1.C @@ -7,7 +7,7 @@ template struct foo { - static void bar(double (*)[dim]) {} // { dg-error "'dim' was not declared" } + static void bar(double (*)[dim]) {} // { dg-error "'dim' was not declared|array bound" } }; void bar() { diff --git a/gcc/testsuite/g++.old-deja/g++.other/friend8.C b/gcc/testsuite/g++.old-deja/g++.other/friend8.C index bbe4bf59871..c1e93d94ab0 100644 --- a/gcc/testsuite/g++.old-deja/g++.other/friend8.C +++ b/gcc/testsuite/g++.old-deja/g++.other/friend8.C @@ -1,3 +1,4 @@ +// { dg-options "-std=c++98 -pedantic-errors" } // { dg-do assemble } // // Copyright (C) 2000 Free Software Foundation, Inc. diff --git a/gcc/testsuite/g++.old-deja/g++.other/init4.C b/gcc/testsuite/g++.old-deja/g++.other/init4.C index f877f2a87d2..92562ef5845 100644 --- a/gcc/testsuite/g++.old-deja/g++.other/init4.C +++ b/gcc/testsuite/g++.old-deja/g++.other/init4.C @@ -1,3 +1,4 @@ +// { dg-options -std=c++98 } // { dg-do assemble } class error { diff --git a/gcc/testsuite/g++.old-deja/g++.pt/crash32.C b/gcc/testsuite/g++.old-deja/g++.pt/crash32.C index 64ed2290fbb..0be26eab414 100644 --- a/gcc/testsuite/g++.old-deja/g++.pt/crash32.C +++ b/gcc/testsuite/g++.old-deja/g++.pt/crash32.C @@ -1,3 +1,4 @@ +// { dg-options "-std=c++98 -pedantic-errors" } // { dg-do assemble } // Origin: Jason Merrill diff --git a/gcc/testsuite/g++.old-deja/g++.pt/friend38.C b/gcc/testsuite/g++.old-deja/g++.pt/friend38.C index 429e421b897..f2343d0d7d1 100644 --- a/gcc/testsuite/g++.old-deja/g++.pt/friend38.C +++ b/gcc/testsuite/g++.old-deja/g++.pt/friend38.C @@ -1,3 +1,4 @@ +// { dg-options "-std=c++98 -pedantic-errors" } // { dg-do assemble } // Overly simplified from testcase by "B. K. Oxley" diff --git a/gcc/testsuite/lib/prune.exp b/gcc/testsuite/lib/prune.exp index 58b59a49dd6..f5cbc4ca62e 100644 --- a/gcc/testsuite/lib/prune.exp +++ b/gcc/testsuite/lib/prune.exp @@ -30,6 +30,9 @@ proc prune_gcc_output { text } { regsub -all "(^|\n)Please submit.*instructions\[^\n\]*" $text "" text regsub -all "(^|\n)\[0-9\]\[0-9\]* errors\." $text "" text + # Ignore informational notes. + regsub -all "(^|\n)\[^\n\]*: note: \[^\n\]*" $text "" text + # Ignore harmless -fpic warnings. regsub -all "(^|\n)\[^\n\]*: warning: -f(pic|PIC) ignored for target\[^\n\]*" $text "" text regsub -all "(^|\n)\[^\n\]*: warning: -f(pic|PIC)( and -fpic are| is)? not supported\[^\n\]*" $text "" text