File indexing completed on 2026-05-03 08:13:08
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef _LIBCPP___ALGORITHM_IN_FOUND_RESULT_H
0011 #define _LIBCPP___ALGORITHM_IN_FOUND_RESULT_H
0012
0013 #include <__concepts/convertible_to.h>
0014 #include <__config>
0015 #include <__utility/move.h>
0016
0017 #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
0018 # pragma GCC system_header
0019 #endif
0020
0021 _LIBCPP_PUSH_MACROS
0022 #include <__undef_macros>
0023
0024 #if _LIBCPP_STD_VER >= 20
0025
0026 _LIBCPP_BEGIN_NAMESPACE_STD
0027
0028 namespace ranges {
0029 template <class _InIter1>
0030 struct in_found_result {
0031 _LIBCPP_NO_UNIQUE_ADDRESS _InIter1 in;
0032 bool found;
0033
0034 template <class _InIter2>
0035 requires convertible_to<const _InIter1&, _InIter2>
0036 _LIBCPP_HIDE_FROM_ABI constexpr operator in_found_result<_InIter2>() const& {
0037 return {in, found};
0038 }
0039
0040 template <class _InIter2>
0041 requires convertible_to<_InIter1, _InIter2>
0042 _LIBCPP_HIDE_FROM_ABI constexpr operator in_found_result<_InIter2>() && {
0043 return {std::move(in), found};
0044 }
0045 };
0046 }
0047
0048 _LIBCPP_END_NAMESPACE_STD
0049
0050 #endif
0051
0052 _LIBCPP_POP_MACROS
0053
0054 #endif