]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR c++/60786 (In C++11 an explicit instantiation with an unqualified name must...
authorJonathan Wakely <jwakely@redhat.com>
Tue, 15 Apr 2014 19:05:45 +0000 (20:05 +0100)
committerJonathan Wakely <redi@gcc.gnu.org>
Tue, 15 Apr 2014 19:05:45 +0000 (20:05 +0100)
PR c++/60786
* testsuite/20_util/shared_ptr/requirements/explicit_instantiation/
1.cc: Fix invalid explicit instantiations with unqualified names.
* testsuite/20_util/shared_ptr/requirements/explicit_instantiation/
2.cc: Likweise.
* testsuite/20_util/tuple/53648.cc: Likweise.
* testsuite/20_util/weak_ptr/requirements/explicit_instantiation/1.cc:
Likewise.
* testsuite/20_util/weak_ptr/requirements/explicit_instantiation/2.cc:
Likewise.
* testsuite/23_containers/unordered_map/requirements/
debug_container.cc: Likewise.
* testsuite/23_containers/unordered_map/requirements/
explicit_instantiation/3.cc: Likewise.
* testsuite/23_containers/unordered_multimap/requirements/debug.cc:
Likewise.
* testsuite/23_containers/unordered_multimap/requirements/
explicit_instantiation/3.cc: Likewise.
* testsuite/23_containers/unordered_multiset/requirements/debug.cc:
Likewise.
* testsuite/23_containers/unordered_multiset/requirements/
explicit_instantiation/3.cc: Likewise.
* testsuite/23_containers/unordered_set/requirements/
debug_container.cc: Likewise.
* testsuite/23_containers/unordered_set/requirements/
explicit_instantiation/3.cc: Likewise.

From-SVN: r209431

14 files changed:
libstdc++-v3/ChangeLog
libstdc++-v3/testsuite/20_util/shared_ptr/requirements/explicit_instantiation/1.cc
libstdc++-v3/testsuite/20_util/shared_ptr/requirements/explicit_instantiation/2.cc
libstdc++-v3/testsuite/20_util/tuple/53648.cc
libstdc++-v3/testsuite/20_util/weak_ptr/requirements/explicit_instantiation/1.cc
libstdc++-v3/testsuite/20_util/weak_ptr/requirements/explicit_instantiation/2.cc
libstdc++-v3/testsuite/23_containers/unordered_map/requirements/debug_container.cc
libstdc++-v3/testsuite/23_containers/unordered_map/requirements/explicit_instantiation/3.cc
libstdc++-v3/testsuite/23_containers/unordered_multimap/requirements/debug.cc
libstdc++-v3/testsuite/23_containers/unordered_multimap/requirements/explicit_instantiation/3.cc
libstdc++-v3/testsuite/23_containers/unordered_multiset/requirements/debug.cc
libstdc++-v3/testsuite/23_containers/unordered_multiset/requirements/explicit_instantiation/3.cc
libstdc++-v3/testsuite/23_containers/unordered_set/requirements/debug_container.cc
libstdc++-v3/testsuite/23_containers/unordered_set/requirements/explicit_instantiation/3.cc

index a9545ff1271e9e0d883603a3c7d99b97dd9d0bde..a2b739645219102eaacd9ca9526ad003648b5705 100644 (file)
 
        * include/std/atomic: Uglify parameter names.
 
+       PR c++/60786
+       * testsuite/20_util/shared_ptr/requirements/explicit_instantiation/
+       1.cc: Fix invalid explicit instantiations with unqualified names.
+       * testsuite/20_util/shared_ptr/requirements/explicit_instantiation/
+       2.cc: Likweise.
+       * testsuite/20_util/tuple/53648.cc: Likweise.
+       * testsuite/20_util/weak_ptr/requirements/explicit_instantiation/1.cc:
+       Likewise.
+       * testsuite/20_util/weak_ptr/requirements/explicit_instantiation/2.cc:
+       Likewise.
+       * testsuite/23_containers/unordered_map/requirements/
+       debug_container.cc: Likewise.
+       * testsuite/23_containers/unordered_map/requirements/
+       explicit_instantiation/3.cc: Likewise.
+       * testsuite/23_containers/unordered_multimap/requirements/debug.cc:
+       Likewise.
+       * testsuite/23_containers/unordered_multimap/requirements/
+       explicit_instantiation/3.cc: Likewise.
+       * testsuite/23_containers/unordered_multiset/requirements/debug.cc:
+       Likewise.
+       * testsuite/23_containers/unordered_multiset/requirements/
+       explicit_instantiation/3.cc: Likewise.
+       * testsuite/23_containers/unordered_set/requirements/
+       debug_container.cc: Likewise.
+       * testsuite/23_containers/unordered_set/requirements/
+       explicit_instantiation/3.cc: Likewise.
+
 2014-04-14  Jonathan Wakely  <jwakely@redhat.com>
 
        * include/bits/stl_vector.h (_Vector_base::_Vector_impl,
index 40ebec096840826d64de1717f6a1f2253e7580ad..0d81481a75bbdb9644bd5ff80d4267bcb337bc0f 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2006-2014 Free Software Foundation, Inc.
@@ -24,8 +24,7 @@
 #include <testsuite_tr1.h>
 
 using namespace __gnu_test;
-using std::shared_ptr;
-template class shared_ptr<int>;
-template class shared_ptr<void>;
-template class shared_ptr<ClassType>;
-template class shared_ptr<IncompleteClass>;
+template class std::shared_ptr<int>;
+template class std::shared_ptr<void>;
+template class std::shared_ptr<ClassType>;
+template class std::shared_ptr<IncompleteClass>;
index 148375a4ad6773157b1c7c0ea5b0b6336e682c7a..37a0c1d14c013349d9f3bc335b1ddb0bce6686c8 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -27,8 +27,7 @@
 // library this checks the templates can be instantiated for non-default
 // lock policy, for a single-threaded lib this is redundant but harmless.
 using namespace __gnu_test;
-using std::__shared_ptr;
 using std::_S_single;
-template class __shared_ptr<int, _S_single>;
-template class __shared_ptr<ClassType, _S_single>;
-template class __shared_ptr<IncompleteClass, _S_single>;
+template class std::__shared_ptr<int, _S_single>;
+template class std::__shared_ptr<ClassType, _S_single>;
+template class std::__shared_ptr<IncompleteClass, _S_single>;
index 7bde67e7e1c679cc1844428f5b1d08e3e2adc2b0..fb37638f75453af0b41ae5fe1ad1a3b1acbf10fc 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2012-2014 Free Software Foundation, Inc.
@@ -27,10 +27,10 @@ using std::tuple;
 
 struct A { };
 
-template class tuple<tuple<>>;
-template class tuple<tuple<tuple<>>>;
-template class tuple<A, tuple<A, tuple<A, tuple<A>>>>;
-template class tuple<tuple<tuple<A, A>, A>, A>;
+template class std::tuple<tuple<>>;
+template class std::tuple<tuple<tuple<>>>;
+template class std::tuple<A, tuple<A, tuple<A, tuple<A>>>>;
+template class std::tuple<tuple<tuple<A, A>, A>, A>;
 
 // Verify the following QoI properties are preserved
 
index c5a30f2727275c9b708c161a4ad4429f89ba0662..0a15e46b8b6fec6c416ad2011b2308c862d236b4 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2006-2014 Free Software Foundation, Inc.
@@ -24,8 +24,7 @@
 #include <testsuite_tr1.h>
 
 using namespace __gnu_test;
-using std::weak_ptr;
-template class weak_ptr<int>;
-template class weak_ptr<void>;
-template class weak_ptr<ClassType>;
-template class weak_ptr<IncompleteClass>;
+template class std::weak_ptr<int>;
+template class std::weak_ptr<void>;
+template class std::weak_ptr<ClassType>;
+template class std::weak_ptr<IncompleteClass>;
index 5c1e91b7950e4ba2f24c13983af3acc524d1a7ff..c0873a14898d00d1058825f16f4686c8ad5f6edc 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -27,9 +27,8 @@
 // library this checks the templates can be instantiated for non-default
 // lock policy, for a single-threaded lib this is redundant but harmless.
 using namespace __gnu_test;
-using std::__weak_ptr;
 using std::_S_single;
-template class __weak_ptr<int, _S_single>;
-template class __weak_ptr<void, _S_single>;
-template class __weak_ptr<ClassType, _S_single>;
-template class __weak_ptr<IncompleteClass, _S_single>;
+template class std::__weak_ptr<int, _S_single>;
+template class std::__weak_ptr<void, _S_single>;
+template class std::__weak_ptr<ClassType, _S_single>;
+template class std::__weak_ptr<IncompleteClass, _S_single>;
index abd9d2c0bd0fa8ba9868d92dbf8b9548f6e01eb0..c4d3442f672d4336c67a1c4f804f3080fcfc9baa 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
 #include <string>
 #include <debug/unordered_map>
 
-using namespace __gnu_debug;
-
 using std::allocator;
 using std::equal_to;
 using std::hash;
 using std::pair;
 using std::string;
 
-template class unordered_map<string, float>;
-template class unordered_map<string, int,
-                            hash<string>, equal_to<string>, 
-                            allocator<pair<const string, int> > >;
-template class unordered_map<string, float,
-                            hash<string>, equal_to<string>, 
-                            allocator<char> >;
+template class __gnu_debug::unordered_map<string, float>;
+template class __gnu_debug::unordered_map<string, int,
+                                          hash<string>, equal_to<string>, 
+                                          allocator<pair<const string, int>>>;
+template class __gnu_debug::unordered_map<string, float,
+                                          hash<string>, equal_to<string>, 
+                                          allocator<char>>;
index de46c5ce6215da8522854b7ff2e9cec05838eeae..145d23e123f74c97255304b56d84ca07f2623051 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -21,4 +21,5 @@
 #include <unordered_map>
 
 using namespace std;
-template class unordered_map<int, int, hash<int>, equal_to<int>, allocator<char>>;
+template class std::unordered_map<int, int, hash<int>, equal_to<int>,
+                                  allocator<char>>;
index 488dbe5e9ecb30235edbbe15ce7dc78f0cba959d..d2d70764f5c479626cfe1ea9e86ee837085fe555 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -21,8 +21,6 @@
 #include <string>
 #include <debug/unordered_map>
 
-using namespace __gnu_debug;
-
 using std::string;
 
-template class unordered_multimap<string, float>;
+template class __gnu_debug::unordered_multimap<string, float>;
index e3d0f47c42c1b9c714828793d16202a3490f01c1..8640bc320c4cc92b774efff25e207993c3696ec3 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -21,4 +21,5 @@
 #include <unordered_map>
 
 using namespace std;
-template class unordered_multimap<int, int, hash<int>, equal_to<int>, allocator<char>>;
+template class std::unordered_multimap<int, int, hash<int>, equal_to<int>,
+                                       allocator<char>>;
index bc3544119ece3abe64d7ae7f980e8cb2464a313d..5e916ad7685f589e47c42f8d6eb7cff5ae4d7d44 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -21,6 +21,4 @@
 #include <string>
 #include <debug/unordered_set>
 
-using namespace __gnu_debug;
-
-template class unordered_multiset<int>;
+template class __gnu_debug::unordered_multiset<int>;
index 2a81347eed17487308776a58ba5a13c7c968b04b..c4624b59147aea3303d04bbef93492da933441a5 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -21,4 +21,5 @@
 #include <unordered_set>
 
 using namespace std;
-template class unordered_multiset<int, hash<int>, equal_to<int>, allocator<char>>;
+template class std::unordered_multiset<int, hash<int>, equal_to<int>,
+                                       allocator<char>>;
index 948c66266d390ead706ee7a078ecc2a7cd86b2cc..f6ab58588ca9ffacd8f79c01c06db67337d8f88a 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -20,6 +20,4 @@
 
 #include <debug/unordered_set>
 
-using namespace __gnu_debug;
-
-template class unordered_set<int>;
+template class __gnu_debug::unordered_set<int>;
index 5cdcb3e314d9bb31e22d7d7285cd28fd08d8b26a..27be027da6b2ab3491fcb756086e6e042ce92917 100644 (file)
@@ -1,4 +1,4 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-options "-std=gnu++11" }
 // { dg-do compile }
 
 // Copyright (C) 2007-2014 Free Software Foundation, Inc.
@@ -21,4 +21,5 @@
 #include <unordered_set>
 
 using namespace std;
-template class unordered_set<int, hash<int>, equal_to<int>, allocator<char>>;
+template class std::unordered_set<int, hash<int>, equal_to<int>,
+                                  allocator<char>>;