Home | History | Annotate | Download | only in move.iter.op.const
      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 // <iterator>
     11 
     12 // move_iterator
     13 
     14 // move_iterator();
     15 //
     16 //  constexpr in C++17
     17 
     18 #include <iterator>
     19 
     20 #include "test_macros.h"
     21 #include "test_iterators.h"
     22 
     23 template <class It>
     24 void
     25 test()
     26 {
     27     std::move_iterator<It> r;
     28     (void)r;
     29 }
     30 
     31 int main()
     32 {
     33     test<input_iterator<char*> >();
     34     test<forward_iterator<char*> >();
     35     test<bidirectional_iterator<char*> >();
     36     test<random_access_iterator<char*> >();
     37     test<char*>();
     38 
     39 #if TEST_STD_VER > 14
     40     {
     41     constexpr std::move_iterator<const char *> it;
     42     (void)it;
     43     }
     44 #endif
     45 }
     46