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 // UNSUPPORTED: c++03, c++11, c++14, c++17 10 // UNSUPPORTED: libcpp-no-concepts 11 12 // template<class I1, class I2> 13 // concept indirectly_swappable; 14 15 #include <iterator> 16 17 #include <concepts> 18 19 template<class I1, class I2> 20 requires std::indirectly_readable<I1> && std::indirectly_readable<I2> 21 constexpr bool indirectly_swappable_subsumption() { 22 return false; 23 } 24 25 template<class I1, class I2> 26 requires std::indirectly_swappable<I1, I2> 27 constexpr bool indirectly_swappable_subsumption() { 28 return true; 29 } 30 31 static_assert(indirectly_swappable_subsumption<int*, int*>()); 32