brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · accfcdf Raw
37 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, class Out,12//     class R = ranges::less, class P1 = identity, class P2 = identity>13//   concept mergeable = see below;                           // since C++2014 15#include <iterator>16 17#include "test_macros.h"18 19template <class I1, class I2, class O>20void test_subsumption() requires std::input_iterator<I1> && std::input_iterator<I2>;21 22template <class I1, class I2, class O>23void test_subsumption() requires std::weakly_incrementable<O>;24 25template <class I1, class I2, class O>26void test_subsumption() requires std::indirectly_copyable<I1, O> && std::indirectly_copyable<I2, O>;27 28template <class I1, class I2, class O>29void test_subsumption() requires std::indirect_strict_weak_order<I1, I2>;30 31template <class I1, class I2, class O>32constexpr bool test_subsumption() requires std::mergeable<I1, I2, O> {33  return true;34}35 36static_assert(test_subsumption<int*, int*, int*>());37