]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libstdc++-v3/testsuite/23_containers/array/tuple_interface/tuple_element.cc
Add tests and docs for LWG 2212 support
[thirdparty/gcc.git] / libstdc++-v3 / testsuite / 23_containers / array / tuple_interface / tuple_element.cc
index 96e0bfbe72b5942d6e6792875714dbd7003651f9..65da7537df972868a336993f2ab3a7b5810bca2c 100644 (file)
 // with this library; see the file COPYING3.  If not see
 // <http://www.gnu.org/licenses/>.
 
+// NB: Don't include any other headers in this file.
+// LWG 2212 requires <array> to define tuple_element<cv T> specializations.
 #include <array>
-#include <type_traits>
-#include <testsuite_hooks.h>
 
 void
 test01() 
 { 
   bool test __attribute__((unused)) = true;
-  using namespace std;
+  using std::array;
+  using std::tuple_element;
+  // This relies on the fact that <utility> includes <type_traits>:
+  using std::is_same;
 
   const size_t len = 3;
   typedef array<int, len> array_type;