[rtsan] Remove mkfifoat interceptor (#116997)
[llvm-project.git] / libcxx / include / __cxx03 / __fwd / subrange.h
blobaebbd866daeb2dd8b0918fbf3155bab09d61e134
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 //===---------------------------------------------------------------------===//
9 #ifndef _LIBCPP___FWD_SUBRANGE_H
10 #define _LIBCPP___FWD_SUBRANGE_H
12 #include <__cxx03/__concepts/copyable.h>
13 #include <__cxx03/__config>
14 #include <__cxx03/__iterator/concepts.h>
15 #include <__cxx03/cstddef>
17 #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
18 # pragma GCC system_header
19 #endif
21 #if _LIBCPP_STD_VER >= 20
23 _LIBCPP_BEGIN_NAMESPACE_STD
25 namespace ranges {
27 enum class subrange_kind : bool { unsized, sized };
29 template <input_or_output_iterator _Iter, sentinel_for<_Iter> _Sent, subrange_kind _Kind>
30 requires(_Kind == subrange_kind::sized || !sized_sentinel_for<_Sent, _Iter>)
31 class _LIBCPP_TEMPLATE_VIS subrange;
33 template <size_t _Index, class _Iter, class _Sent, subrange_kind _Kind>
34 requires((_Index == 0 && copyable<_Iter>) || _Index == 1)
35 _LIBCPP_HIDE_FROM_ABI constexpr auto get(const subrange<_Iter, _Sent, _Kind>&);
37 template <size_t _Index, class _Iter, class _Sent, subrange_kind _Kind>
38 requires(_Index < 2)
39 _LIBCPP_HIDE_FROM_ABI constexpr auto get(subrange<_Iter, _Sent, _Kind>&&);
41 } // namespace ranges
43 using ranges::get;
45 _LIBCPP_END_NAMESPACE_STD
47 #endif // _LIBCPP_STD_VER >= 20
49 #endif // _LIBCPP___FWD_SUBRANGE_H