* [v3] check_compile_only cleanups
@ 2010-12-16 22:47 Benjamin Kosnik
0 siblings, 0 replies; only message in thread
From: Benjamin Kosnik @ 2010-12-16 22:47 UTC (permalink / raw)
To: gcc-patches, libstdc++
[-- Attachment #1: Type: text/plain, Size: 158 bytes --]
Add _neg suffix to neg tests without it.
Some C++0x fixups for the testsuite directory.
De-macrofication for pb_ds tests.
tested x86/64 linux
-benjamin
[-- Attachment #2: 20101216-0.patch --]
[-- Type: text/x-patch, Size: 35048 bytes --]
2010-11-16 Benjamin Kosnik <bkoz@redhat.com>
* testsuite/util/testsuite_iterators.h: Guard move.h includes.
* testsuite/util/testsuite_allocator.h: Same.
* testsuite/20_util/temporary_buffer.cc: Use typedef, qualify.
* testsuite/ext/pb_ds/regression/hash_data_map_rand.cc: Define
PB_DS_REGRESSION in the source file.
* testsuite/ext/pb_ds/regression/trie_data_map_rand.cc: Same.
* testsuite/ext/pb_ds/regression/list_update_no_data_map_rand.cc: Same.
* testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc: Same.
* testsuite/ext/pb_ds/regression/list_update_data_map_rand.cc: Same.
* testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc: Same.
* testsuite/ext/pb_ds/regression/priority_queue_rand.cc: Same.
* testsuite/ext/pb_ds/regression/tree_data_map_rand.cc: Same.
* testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc: Same.
* testsuite/21_strings/c_strings/wchar_t/3_neg.cc: Move to this.
Use _neg suffix.
* testsuite/21_strings/c_strings/wchar_t/3.cc: ...from this.
* testsuite/21_strings/c_strings/char/3_neg.cc: Same.
* testsuite/21_strings/c_strings/char/3.cc: Same.
* testsuite/ext/slist/23781_neg.cc: Same.
* testsuite/ext/slist/23781.cc: Same.
* testsuite/ext/profile/mutex_extensions.cc: Same.
* testsuite/ext/profile/mutex_extensions_neg.cc: Same.
* testsuite/tr1/2_general_utilities/shared_ptr/cons/43820.cc: Same.
* testsuite/tr1/2_general_utilities/shared_ptr/cons/43820_neg.cc: Same.
* testsuite/tr1/6_containers/tuple/comparison_operators/35480_neg.cc:
Same.
* testsuite/tr1/6_containers/tuple/comparison_operators/35480.cc: Same.
* testsuite/23_containers/multimap/23781_neg.cc: Same.
* testsuite/23_containers/multimap/23781.cc: Same.
* testsuite/23_containers/set/23781_neg.cc: Same.
* testsuite/23_containers/set/23781.cc: Same.
* testsuite/23_containers/multiset/23781_neg.cc: Same.
* testsuite/23_containers/multiset/23781.cc: Same.
* testsuite/23_containers/list/23781_neg.cc: Same.
* testsuite/23_containers/list/23781.cc: Same.
* testsuite/23_containers/map/23781_neg.cc: Same.
* testsuite/23_containers/map/23781.cc: Same.
* testsuite/20_util/duration/cons/dr974_neg.cc: Same.
* testsuite/20_util/duration/cons/dr974.cc: Same.
* testsuite/20_util/tuple/comparison_operators/35480_neg.cc: Same.
* testsuite/20_util/tuple/comparison_operators/35480.cc: Same.
* testsuite/20_util/shared_ptr/cons/43820_neg.cc: Same.
* testsuite/20_util/shared_ptr/cons/43820.cc: Same.
* testsuite/20_util/unique_ptr/cons/pointer_array_convertible_neg.cc:
Same.
* testsuite/20_util/unique_ptr/cons/pointer_array_convertible.cc: Same.
Index: testsuite/21_strings/c_strings/wchar_t/3.cc
===================================================================
--- testsuite/21_strings/c_strings/wchar_t/3.cc (revision 167951)
+++ testsuite/21_strings/c_strings/wchar_t/3.cc (working copy)
@@ -1,52 +0,0 @@
-// { dg-do compile { target correct_iso_cpp_string_wchar_protos } }
-// { dg-options "-O2" }
-
-// Copyright (C) 2009 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-#include <cwchar>
-
-const wchar_t *cw1, *cw2;
-wchar_t *w1, *w2;
-
-void
-test01 ()
-{
- w1 = wmemchr (w2, L'/', 3);
- w1 = wcschr (w2, L'/');
- w1 = wcspbrk (w2, L"abc");
- w1 = wcsrchr (w2, L'c');
- w1 = wcsstr (w2, L"abc");
-
- cw1 = wmemchr (w2, L'/', 3);
- cw1 = wcschr (w2, L'/');
- cw1 = wcspbrk (w2, L"abc");
- cw1 = wcsrchr (w2, L'c');
- cw1 = wcsstr (w2, L"abc");
-
- w1 = wmemchr (cw2, L'/', 3); // { dg-error "invalid conversion" }
- w1 = wcschr (cw2, L'/'); // { dg-error "invalid conversion" }
- w1 = wcsrchr (cw2, L'c'); // { dg-error "invalid conversion" }
- w1 = wcspbrk (cw2, L"abc"); // { dg-error "invalid conversion" }
- w1 = wcsstr (cw2, L"abc"); // { dg-error "invalid conversion" }
-
- cw1 = wmemchr (cw2, L'/', 3);
- cw1 = wcschr (cw2, L'/');
- cw1 = wcspbrk (cw2, L"abc");
- cw1 = wcsrchr (cw2, L'c');
- cw1 = wcsstr (cw2, L"abc");
-}
Index: testsuite/21_strings/c_strings/char/3.cc
===================================================================
--- testsuite/21_strings/c_strings/char/3.cc (revision 167951)
+++ testsuite/21_strings/c_strings/char/3.cc (working copy)
@@ -1,54 +0,0 @@
-// { dg-do compile { target correct_iso_cpp_string_wchar_protos } }
-// { dg-options "-O2" }
-
-// Copyright (C) 2009 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-#include <cstring>
-
-const char *cc1, *cc2;
-char *c1, *c2;
-const void *cv1, *cv2;
-void *v1, *v2;
-
-void
-test01 ()
-{
- v1 = std::memchr (v2, '/', 3);
- c1 = std::strchr (c2, '/');
- c1 = std::strrchr (c2, 'c');
- c1 = std::strpbrk (c2, "abc");
- c1 = std::strstr (c2, "abc");
-
- cv1 = std::memchr (v2, '/', 3);
- cc1 = std::strchr (c2, '/');
- cc1 = std::strrchr (c2, 'c');
- cc1 = std::strpbrk (c2, "abc");
- cc1 = std::strstr (c2, "abc");
-
- v1 = std::memchr (cv2, '/', 3); // { dg-error "invalid conversion" }
- c1 = std::strchr (cc2, '/'); // { dg-error "invalid conversion" }
- c1 = std::strrchr (cc2, 'c'); // { dg-error "invalid conversion" }
- c1 = std::strpbrk (cc2, "abc"); // { dg-error "invalid conversion" }
- c1 = std::strstr (cc2, "abc"); // { dg-error "invalid conversion" }
-
- cv1 = std::memchr (cv2, '/', 3);
- cc1 = std::strchr (cc2, '/');
- cc1 = std::strrchr (cc2, 'c');
- cc1 = std::strpbrk (cc2, "abc");
- cc1 = std::strstr (cc2, "abc");
-}
Index: testsuite/ext/pb_ds/regression/hash_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/hash_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/hash_data_map_rand.cc (working copy)
@@ -1,4 +1,8 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+// This can take long on simulators, timing out the test.
+// { dg-options "-DITERATIONS=5" { target simulator } }
+// { dg-timeout-factor 2.0 }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,14 +39,11 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
-// This can take long on simulators, timing out the test.
-// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
-// { dg-timeout-factor 2.0 }
#ifndef ITERATIONS
#define ITERATIONS 5000
#endif
Index: testsuite/ext/pb_ds/regression/trie_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/trie_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/trie_data_map_rand.cc (working copy)
@@ -1,4 +1,8 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+// This can take long on simulators, timing out the test.
+// { dg-options "-DITERATIONS=5" { target simulator } }
+// { dg-timeout-factor 2.0 }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,14 +39,11 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
-// This can take long on simulators, timing out the test.
-// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
-// { dg-timeout-factor 2.0 }
#ifndef ITERATIONS
#define ITERATIONS 5000
#endif
Index: testsuite/ext/pb_ds/regression/list_update_no_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/list_update_no_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/list_update_no_data_map_rand.cc (working copy)
@@ -1,4 +1,5 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,7 +36,7 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
Index: testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/tree_no_data_map_rand.cc (working copy)
@@ -1,4 +1,8 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+// This can take long on simulators, timing out the test.
+// { dg-options "-DITERATIONS=5" { target simulator } }
+// { dg-timeout-factor 2.0 }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,14 +39,11 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
-// This can take long on simulators, timing out the test.
-// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
-// { dg-timeout-factor 2.0 }
#ifndef ITERATIONS
#define ITERATIONS 5000
#endif
Index: testsuite/ext/pb_ds/regression/list_update_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/list_update_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/list_update_data_map_rand.cc (working copy)
@@ -1,4 +1,5 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,7 +36,7 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
Index: testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/hash_no_data_map_rand.cc (working copy)
@@ -1,4 +1,8 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+// This can take long on simulators, timing out the test.
+// { dg-options "-DITERATIONS=5" { target simulator } }
+// { dg-timeout-factor 2.0 }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,14 +39,11 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
-// This can take long on simulators, timing out the test.
-// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
-// { dg-timeout-factor 2.0 }
#ifndef ITERATIONS
#define ITERATIONS 5000
#endif
Index: testsuite/ext/pb_ds/regression/priority_queue_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/priority_queue_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/priority_queue_rand.cc (working copy)
@@ -1,4 +1,8 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+// This can take long on simulators, timing out the test.
+// { dg-options "-DITERATIONS=5" { target simulator } }
+// { dg-timeout-factor 2.0 }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,14 +39,11 @@
* Contains a random-operation test for priority queues.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/priority_queue/rand_regression_test.hpp>
#include <regression/common_type.hpp>
-// This can take long on simulators, timing out the test.
-// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
-// { dg-timeout-factor 2.0 }
#ifndef ITERATIONS
#define ITERATIONS 5000
#endif
Index: testsuite/ext/pb_ds/regression/tree_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/tree_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/tree_data_map_rand.cc (working copy)
@@ -1,4 +1,8 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+// This can take long on simulators, timing out the test.
+// { dg-options "-DITERATIONS=5" { target simulator } }
+// { dg-timeout-factor 2.0 }
+
// -*- C++ -*-
// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
@@ -35,14 +39,11 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
-// This can take long on simulators, timing out the test.
-// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
-// { dg-timeout-factor 2.0 }
#ifndef ITERATIONS
#define ITERATIONS 5000
#endif
Index: testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc
===================================================================
--- testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc (revision 167951)
+++ testsuite/ext/pb_ds/regression/trie_no_data_map_rand.cc (working copy)
@@ -1,7 +1,11 @@
-// { dg-options "-DPB_DS_REGRESSION" }
+// { dg-require-time "" }
+// This can take long on simulators, timing out the test.
+// { dg-options "-DITERATIONS=5" { target simulator } }
+// { dg-timeout-factor 2.0 }
+
// -*- C++ -*-
-// Copyright (C) 2005, 2006, 2009 Free Software Foundation, Inc.
+// Copyright (C) 2005, 2006, 2009, 2010 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the terms
@@ -35,14 +39,11 @@
* Contains a random-operation test for maps and sets.
*/
-// { dg-require-time "" }
+#define PB_DS_REGRESSION
#include <regression/rand/assoc/rand_regression_test.hpp>
#include <regression/common_type.hpp>
-// This can take long on simulators, timing out the test.
-// { dg-options "-DPB_DS_REGRESSION -DITERATIONS=5" { target simulator } }
-// { dg-timeout-factor 2.0 }
#ifndef ITERATIONS
#define ITERATIONS 5000
#endif
Index: testsuite/ext/slist/23781.cc
===================================================================
--- testsuite/ext/slist/23781.cc (revision 167951)
+++ testsuite/ext/slist/23781.cc (working copy)
@@ -1,28 +0,0 @@
-// 2005-09-10 Paolo Carlini <pcarlini@suse.de>
-//
-// Copyright (C) 2005, 2009, 2010 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-//
-
-// { dg-do compile }
-
-// libstdc++/23781
-#include <ext/slist>
-#include <cstddef>
-
-__gnu_cxx::slist<int>::iterator it = NULL; // { dg-error "conversion" }
-__gnu_cxx::slist<int>::const_iterator cit = NULL; // { dg-error "conversion" }
Index: testsuite/ext/profile/mutex_extensions.cc
===================================================================
--- testsuite/ext/profile/mutex_extensions.cc (revision 167951)
+++ testsuite/ext/profile/mutex_extensions.cc (working copy)
@@ -1,25 +0,0 @@
-// { dg-options "-D_GLIBCXX_DEBUG -D_GLIBCXX_PROFILE" }
-// { dg-do compile }
-
-// -*- C++ -*-
-
-// Copyright (C) 2006, 2007, 2009, 2010 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-#include <vector>
-
-// { dg-error "Cannot use -D_GLIBCXX_PROFILE with " "" { target *-*-* } 223 }
Index: testsuite/tr1/2_general_utilities/shared_ptr/cons/43820.cc
===================================================================
--- testsuite/tr1/2_general_utilities/shared_ptr/cons/43820.cc (revision 167951)
+++ testsuite/tr1/2_general_utilities/shared_ptr/cons/43820.cc (working copy)
@@ -1,38 +0,0 @@
-// { dg-do compile }
-
-// Copyright (C) 2010 Free Software Foundation
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-// 2.2.3 Class template shared_ptr [tr.util.smartptr.shared]
-
-#include <tr1/memory>
-
-// incomplete type
-struct X;
-
-std::auto_ptr<X>& ap();
-
-void test01()
-{
- X* px = 0;
- std::tr1::shared_ptr<X> p1(px); // { dg-error "here" }
- // { dg-error "incomplete" "" { target *-*-* } 561 }
-
- std::tr1::shared_ptr<X> p9(ap()); // { dg-error "here" }
- // { dg-error "incomplete" "" { target *-*-* } 600 }
-
-}
Index: testsuite/tr1/6_containers/tuple/comparison_operators/35480.cc
===================================================================
--- testsuite/tr1/6_containers/tuple/comparison_operators/35480.cc (revision 167951)
+++ testsuite/tr1/6_containers/tuple/comparison_operators/35480.cc (working copy)
@@ -1,32 +0,0 @@
-// { dg-do compile }
-
-// Copyright (C) 2008, 2009 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-// Tuple
-
-#include <tr1/tuple>
-
-// libstdc++/35480
-void test01()
-{
- std::tr1::tuple<int> t1( 1 );
- std::tr1::tuple<int, int> t2( 1, 2 );
- if ( t1 < t2 ) {} // { dg-error "here" }
- if ( t1 == t2 ) {} // { dg-error "here" }
-}
-// { dg-excess-errors "incomplete type" }
Index: testsuite/23_containers/multimap/23781.cc
===================================================================
--- testsuite/23_containers/multimap/23781.cc (revision 167951)
+++ testsuite/23_containers/multimap/23781.cc (working copy)
@@ -1,28 +0,0 @@
-// 2005-09-10 Paolo Carlini <pcarlini@suse.de>
-//
-// Copyright (C) 2005, 2009, 2010 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-//
-
-// { dg-do compile }
-
-// libstdc++/23781
-#include <map>
-#include <cstddef>
-
-std::multimap<int, int>::iterator it = NULL; // { dg-error "conversion" }
-std::multimap<int, int>::const_iterator cit = NULL; // { dg-error "conversion" }
Index: testsuite/23_containers/set/23781.cc
===================================================================
--- testsuite/23_containers/set/23781.cc (revision 167951)
+++ testsuite/23_containers/set/23781.cc (working copy)
@@ -1,28 +0,0 @@
-// 2005-09-10 Paolo Carlini <pcarlini@suse.de>
-//
-// Copyright (C) 2005, 2009, 2010 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-//
-
-// { dg-do compile }
-
-// libstdc++/23781
-#include <set>
-#include <cstddef>
-
-std::set<int>::iterator it = NULL; // { dg-error "conversion" }
-std::set<int>::const_iterator cit = NULL; // { dg-error "conversion" }
Index: testsuite/23_containers/multiset/23781.cc
===================================================================
--- testsuite/23_containers/multiset/23781.cc (revision 167951)
+++ testsuite/23_containers/multiset/23781.cc (working copy)
@@ -1,28 +0,0 @@
-// 2005-09-10 Paolo Carlini <pcarlini@suse.de>
-//
-// Copyright (C) 2005, 2009, 2010 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-//
-
-// { dg-do compile }
-
-// libstdc++/23781
-#include <set>
-#include <cstddef>
-
-std::multiset<int>::iterator it = NULL; // { dg-error "conversion" }
-std::multiset<int>::const_iterator cit = NULL; // { dg-error "conversion" }
Index: testsuite/23_containers/list/23781.cc
===================================================================
--- testsuite/23_containers/list/23781.cc (revision 167951)
+++ testsuite/23_containers/list/23781.cc (working copy)
@@ -1,29 +0,0 @@
-// 2005-09-10 Paolo Carlini <pcarlini@suse.de>
-//
-// Copyright (C) 2005, 2009, 2010 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-//
-
-// { dg-do compile }
-
-// libstdc++/23781
-#include <list>
-#include <cstddef>
-
-typedef std::list<int> list_type;
-list_type::iterator it = NULL; // { dg-error "conversion" }
-list_type::const_iterator cit = NULL; // { dg-error "conversion" }
Index: testsuite/23_containers/map/23781.cc
===================================================================
--- testsuite/23_containers/map/23781.cc (revision 167951)
+++ testsuite/23_containers/map/23781.cc (working copy)
@@ -1,28 +0,0 @@
-// 2005-09-10 Paolo Carlini <pcarlini@suse.de>
-//
-// Copyright (C) 2005, 2009, 2010 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-//
-
-// { dg-do compile }
-
-// libstdc++/23781
-#include <map>
-#include <cstddef>
-
-std::map<int, int>::iterator it = NULL; // { dg-error "conversion" }
-std::map<int, int>::const_iterator cit = NULL; // { dg-error "conversion" }
Index: testsuite/util/testsuite_iterators.h
===================================================================
--- testsuite/util/testsuite_iterators.h (revision 167951)
+++ testsuite/util/testsuite_iterators.h (working copy)
@@ -30,7 +30,10 @@
#include <testsuite_hooks.h>
#include <bits/stl_iterator_base_types.h>
+
+#ifdef __GXX_EXPERIMENTAL_CXX0X__
#include <bits/move.h>
+#endif
#ifndef _TESTSUITE_ITERATORS
#define _TESTSUITE_ITERATORS
Index: testsuite/util/testsuite_allocator.h
===================================================================
--- testsuite/util/testsuite_allocator.h (revision 167951)
+++ testsuite/util/testsuite_allocator.h (working copy)
@@ -29,7 +29,10 @@
#include <tr1/unordered_map>
#include <cassert>
+
+#ifdef __GXX_EXPERIMENTAL_CXX0X__
#include <bits/move.h>
+#endif
namespace __gnu_test
{
Index: testsuite/20_util/duration/cons/dr974.cc
===================================================================
--- testsuite/20_util/duration/cons/dr974.cc (revision 167951)
+++ testsuite/20_util/duration/cons/dr974.cc (working copy)
@@ -1,33 +0,0 @@
-// { dg-do compile }
-// { dg-options "-std=gnu++0x" }
-// { dg-require-cstdint "" }
-
-// Copyright (C) 2009 Free Software Foundation
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-// 20.8.3.1 duration constructors [time.duration.cons]
-
-#include <chrono>
-
-// DR 974.
-void test01()
-{
- using namespace std::chrono;
-
- duration<double> d(3.5);
- duration<int> i = d; // { dg-error "conversion" }
-}
Index: testsuite/20_util/tuple/comparison_operators/35480.cc
===================================================================
--- testsuite/20_util/tuple/comparison_operators/35480.cc (revision 167951)
+++ testsuite/20_util/tuple/comparison_operators/35480.cc (working copy)
@@ -1,33 +0,0 @@
-// { dg-options "-std=gnu++0x" }
-// { dg-do compile }
-
-// Copyright (C) 2008, 2009 Free Software Foundation, Inc.
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-// Tuple
-
-#include <tuple>
-
-// libstdc++/35480
-void test01()
-{
- std::tuple<int> t1( 1 );
- std::tuple<int, int> t2( 1, 2 );
- if ( t1 < t2 ) {} // { dg-error "here" }
- if ( t1 == t2 ) {} // { dg-error "here" }
-}
-// { dg-excess-errors "incomplete type" }
Index: testsuite/20_util/shared_ptr/cons/43820.cc
===================================================================
--- testsuite/20_util/shared_ptr/cons/43820.cc (revision 167951)
+++ testsuite/20_util/shared_ptr/cons/43820.cc (working copy)
@@ -1,40 +0,0 @@
-// { dg-options "-std=gnu++0x" }
-// { dg-do compile }
-
-// Copyright (C) 2010 Free Software Foundation
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-// 20.9.11.2 Template class shared_ptr [util.smartptr.shared]
-
-#include <memory>
-
-// incomplete type
-struct X;
-
-// get an auto_ptr rvalue
-std::auto_ptr<X>&& ap();
-
-void test01()
-{
- X* px = 0;
- std::shared_ptr<X> p1(px); // { dg-error "here" }
- // { dg-error "incomplete" "" { target *-*-* } 763 }
-
- std::shared_ptr<X> p9(ap()); // { dg-error "here" }
- // { dg-error "incomplete" "" { target *-*-* } 855 }
-
-}
Index: testsuite/20_util/unique_ptr/cons/pointer_array_convertible.cc
===================================================================
--- testsuite/20_util/unique_ptr/cons/pointer_array_convertible.cc (revision 167951)
+++ testsuite/20_util/unique_ptr/cons/pointer_array_convertible.cc (working copy)
@@ -1,41 +0,0 @@
-// { dg-do compile }
-// { dg-options "-std=gnu++0x" }
-
-// Copyright (C) 2008, 2009 Free Software Foundation
-//
-// This file is part of the GNU ISO C++ Library. This library is free
-// software; you can redistribute it and/or modify it under the
-// terms of the GNU General Public License as published by the
-// Free Software Foundation; either version 3, or (at your option)
-// any later version.
-
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License along
-// with this library; see the file COPYING3. If not see
-// <http://www.gnu.org/licenses/>.
-
-#include <memory>
-
-struct A
-{
-};
-
-struct B : A
-{
- virtual ~B() { }
-};
-
-// 20.4.5.1 unique_ptr constructors [unique.ptr.cons]
-
-// Construction from pointer of derived type
-void
-test01()
-{
- std::unique_ptr<B[]> B_from_A(new A[3]); //{ dg-error "invalid conversion from" }
-}
-
-// { dg-prune-output "include" }
Index: testsuite/20_util/temporary_buffer.cc
===================================================================
--- testsuite/20_util/temporary_buffer.cc (revision 167951)
+++ testsuite/20_util/temporary_buffer.cc (working copy)
@@ -28,7 +28,8 @@
{
bool test __attribute__((unused)) = true;
- std::pair<junk*,ptrdiff_t> results = std::get_temporary_buffer<junk>(5);
+ typedef std::pair<junk*, std::ptrdiff_t> pair_type;
+ pair_type results = std::get_temporary_buffer<junk>(5);
if (results.second != 0)
{
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2010-12-16 22:12 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-16 22:47 [v3] check_compile_only cleanups Benjamin Kosnik
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).