This patch fixes some miscellaneous stuff in the testsuite. See https://gcc.gnu.org/ml/gcc-patches/2014-09/msg02656.html for more info.
Tested on x86_64-linux: vanilla results == results with this patch == results with this patch and gnu11 as a default. Applying to trunk. 2014-10-06 Marek Polacek <pola...@redhat.com> boehm-gc/ * testsuite/boehm-gc.c/gctest.c: Fix defaulting to int. gcc/testsuite/ * c-c++-common/raw-string-3.c: Use -std=gnu89 for C. * g++.dg/lto/pr54625-1_0.c: Fix defaulting to int. * g++.dg/lto/pr54625-2_0.c: Likewise. * gcc.misc-tests/gcov-14.c: Use -fgnu89-inline. diff --git gcc/boehm-gc/testsuite/boehm-gc.c/gctest.c gcc/boehm-gc/testsuite/boehm-gc.c/gctest.c index 1180ab1..cc03e96 100644 --- gcc/boehm-gc/testsuite/boehm-gc.c/gctest.c +++ gcc/boehm-gc/testsuite/boehm-gc.c/gctest.c @@ -1701,6 +1701,7 @@ int APIENTRY WinMain(HINSTANCE instance, HINSTANCE prev, LPSTR cmd, int n) #ifdef PCR +int test() { PCR_Th_T * th1; @@ -1738,6 +1739,7 @@ void * thr_run_one_test(void * arg) #endif #if defined(GC_SOLARIS_THREADS) && !defined(GC_SOLARIS_PTHREADS) +int main() { thread_t th1; @@ -1781,6 +1783,7 @@ main() --> bad news #endif +int main() { pthread_t th1; diff --git gcc/gcc/testsuite/c-c++-common/raw-string-3.c gcc/gcc/testsuite/c-c++-common/raw-string-3.c index 1dde113..326e309 100644 --- gcc/gcc/testsuite/c-c++-common/raw-string-3.c +++ gcc/gcc/testsuite/c-c++-common/raw-string-3.c @@ -1,7 +1,7 @@ // If not c++0x/gnu99, the {,u,u8,U,L}R prefix should be parsed as separate // token. // { dg-do compile } -// { dg-options "" { target c } } +// { dg-options "-std=gnu89" { target c } } // { dg-options "-std=c++98" { target c++ } } const void *s0 = R"(a)"; // { dg-error "was not declared|undeclared" "undeclared" } diff --git gcc/gcc/testsuite/g++.dg/lto/pr54625-1_0.c gcc/gcc/testsuite/g++.dg/lto/pr54625-1_0.c index 5ab90dd..48bbdf0 100644 --- gcc/gcc/testsuite/g++.dg/lto/pr54625-1_0.c +++ gcc/gcc/testsuite/g++.dg/lto/pr54625-1_0.c @@ -3,6 +3,7 @@ float a; double sin (); +void speex_resampler_init_frac () { a = sin (0); diff --git gcc/gcc/testsuite/g++.dg/lto/pr54625-2_0.c gcc/gcc/testsuite/g++.dg/lto/pr54625-2_0.c index 6511ba5..3e67d4f 100644 --- gcc/gcc/testsuite/g++.dg/lto/pr54625-2_0.c +++ gcc/gcc/testsuite/g++.dg/lto/pr54625-2_0.c @@ -3,6 +3,7 @@ float a; double sin (); +void update_filter () { a = sin (0); diff --git gcc/gcc/testsuite/gcc.misc-tests/gcov-14.c gcc/gcc/testsuite/gcc.misc-tests/gcov-14.c index de7ac0d..78dd7be 100644 --- gcc/gcc/testsuite/gcc.misc-tests/gcov-14.c +++ gcc/gcc/testsuite/gcc.misc-tests/gcov-14.c @@ -1,6 +1,6 @@ /* Test gcov extern inline. */ -/* { dg-options "-O2 -fprofile-arcs -ftest-coverage" } */ +/* { dg-options "-O2 -fprofile-arcs -ftest-coverage -fgnu89-inline" } */ /* The following line arranges that Darwin has behavior like elf weak import. */ /* { dg-additional-options "-flat_namespace -undefined suppress" { target *-*-darwin* } } */ /* { dg-require-weak "" } */ Marek