brintos

brintos / llvm-project-archived public Read only

0
0
Text · 901 B · 20701db Raw
31 lines · cpp
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-exception6//7//===----------------------------------------------------------------------===//8 9// UNSUPPORTED: c++03, c++11, c++14, c++1710 11// template<class I1, class I2>12// concept indirectly_swappable;13 14#include <iterator>15 16#include <concepts>17 18template<class I1, class I2>19  requires std::indirectly_readable<I1> && std::indirectly_readable<I2>20constexpr bool indirectly_swappable_subsumption() {21  return false;22}23 24template<class I1, class I2>25  requires std::indirectly_swappable<I1, I2>26constexpr bool indirectly_swappable_subsumption() {27  return true;28}29 30static_assert(indirectly_swappable_subsumption<int*, int*>());31