Home | History | Annotate | Download | only in tuple.cnstr
      1 //===----------------------------------------------------------------------===//
      2 //
      3 //                     The LLVM Compiler Infrastructure
      4 //
      5 // This file is dual licensed under the MIT and the University of Illinois Open
      6 // Source Licenses. See LICENSE.TXT for details.
      7 //
      8 //===----------------------------------------------------------------------===//
      9 
     10 // UNSUPPORTED: c++98, c++03
     11 
     12 // <tuple>
     13 
     14 // template <class... Types> class tuple;
     15 
     16 // ~tuple();
     17 
     18 #include <tuple>
     19 #include <string>
     20 #include <cassert>
     21 #include <type_traits>
     22 
     23 int main()
     24 {
     25   static_assert(std::is_trivially_destructible<
     26       std::tuple<> >::value, "");
     27   static_assert(std::is_trivially_destructible<
     28       std::tuple<void*> >::value, "");
     29   static_assert(std::is_trivially_destructible<
     30       std::tuple<int, float> >::value, "");
     31   static_assert(!std::is_trivially_destructible<
     32       std::tuple<std::string> >::value, "");
     33   static_assert(!std::is_trivially_destructible<
     34       std::tuple<int, std::string> >::value, "");
     35 }
     36