Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/boost/parser/detail/text/in_out_result.hpp was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // Copyright (C) 2020 T. Zachary Laine
0002 //
0003 // Distributed under the Boost Software License, Version 1.0. (See
0004 // accompanying file LICENSE_1_0.txt or copy at
0005 // http://www.boost.org/LICENSE_1_0.txt)
0006 #ifndef BOOST_PARSER_DETAIL_TEXT_IN_OUT_RESULT_HPP
0007 #define BOOST_PARSER_DETAIL_TEXT_IN_OUT_RESULT_HPP
0008 
0009 #include <boost/parser/detail/text/config.hpp>
0010 
0011 
0012 namespace boost::parser::detail { namespace text {
0013 
0014     /** A replacement for C++20's `std::ranges::in_out_result` for use in
0015         pre-C++20 build modes. */
0016     template<typename I, typename O>
0017     struct in_out_result
0018     {
0019         [[no_unique_address]] I in;
0020         [[no_unique_address]] O out;
0021     };
0022 
0023 }}
0024 
0025 #if BOOST_PARSER_DETAIL_TEXT_USE_CONCEPTS
0026 
0027 #include <ranges>
0028 
0029 namespace boost::parser::detail { namespace text { BOOST_PARSER_DETAIL_TEXT_NAMESPACE_V2 {
0030 
0031     namespace dtl {
0032         template<typename R>
0033         std::ranges::borrowed_iterator_t<R> result_iterator(R &&);
0034         template<typename Ptr>
0035             requires std::is_pointer_v<std::remove_reference_t<Ptr>>
0036         Ptr result_iterator(Ptr &&);
0037 
0038         template<typename T>
0039         using uc_result_iterator =
0040             decltype(dtl::result_iterator(std::declval<T>()));
0041     }
0042 
0043 }}}
0044 
0045 #endif
0046 
0047 #endif