1 //===----------------------------------------------------------------------===// 2 // 3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4 // See https://llvm.org/LICENSE.txt for license information. 5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6 // 7 //===----------------------------------------------------------------------===// 8 9 // <iterator> 10 11 // struct bidirectional_iterator_tag : public forward_iterator_tag {}; 12 13 #include <iterator> 14 #include <type_traits> 15 16 #include "test_macros.h" 17 main(int,char **)18int main(int, char**) 19 { 20 std::bidirectional_iterator_tag tag; 21 ((void)tag); // Prevent unused warning 22 static_assert((std::is_base_of<std::forward_iterator_tag, 23 std::bidirectional_iterator_tag>::value), ""); 24 static_assert((!std::is_base_of<std::output_iterator_tag, 25 std::bidirectional_iterator_tag>::value), ""); 26 27 return 0; 28 } 29