Skip to content

Commit 33b0c53

Browse files
committed
Update vendor
1 parent cf7d306 commit 33b0c53

File tree

257 files changed

+9168
-4658
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

257 files changed

+9168
-4658
lines changed

Diff for: example/vendor/cget/pkg/chriskohlhoff__asio/install/include/asio.hpp

+6
Original file line numberDiff line numberDiff line change
@@ -59,19 +59,24 @@
5959
#include "asio/buffered_write_stream_fwd.hpp"
6060
#include "asio/buffered_write_stream.hpp"
6161
#include "asio/buffers_iterator.hpp"
62+
#include "asio/cancel_after.hpp"
63+
#include "asio/cancel_at.hpp"
6264
#include "asio/cancellation_signal.hpp"
6365
#include "asio/cancellation_state.hpp"
6466
#include "asio/cancellation_type.hpp"
67+
#include "asio/co_composed.hpp"
6568
#include "asio/co_spawn.hpp"
6669
#include "asio/completion_condition.hpp"
6770
#include "asio/compose.hpp"
71+
#include "asio/composed.hpp"
6872
#include "asio/connect.hpp"
6973
#include "asio/connect_pipe.hpp"
7074
#include "asio/consign.hpp"
7175
#include "asio/coroutine.hpp"
7276
#include "asio/deadline_timer.hpp"
7377
#include "asio/defer.hpp"
7478
#include "asio/deferred.hpp"
79+
#include "asio/default_completion_token.hpp"
7580
#include "asio/detached.hpp"
7681
#include "asio/dispatch.hpp"
7782
#include "asio/error.hpp"
@@ -100,6 +105,7 @@
100105
#include "asio/generic/stream_protocol.hpp"
101106
#include "asio/handler_continuation_hook.hpp"
102107
#include "asio/high_resolution_timer.hpp"
108+
#include "asio/immediate.hpp"
103109
#include "asio/io_context.hpp"
104110
#include "asio/io_context_strand.hpp"
105111
#include "asio/io_service.hpp"

Diff for: example/vendor/cget/pkg/chriskohlhoff__asio/install/include/asio/as_tuple.hpp

+35-9
Original file line numberDiff line numberDiff line change
@@ -106,16 +106,42 @@ class as_tuple_t
106106
CompletionToken token_;
107107
};
108108

109-
/// Adapt a @ref completion_token to specify that the completion handler
110-
/// arguments should be combined into a single tuple argument.
111-
template <typename CompletionToken>
112-
ASIO_NODISCARD inline
113-
constexpr as_tuple_t<decay_t<CompletionToken>>
114-
as_tuple(CompletionToken&& completion_token)
109+
/// A function object type that adapts a @ref completion_token to specify that
110+
/// the completion handler arguments should be combined into a single tuple
111+
/// argument.
112+
/**
113+
* May also be used directly as a completion token, in which case it adapts the
114+
* asynchronous operation's default completion token (or asio::deferred
115+
* if no default is available).
116+
*/
117+
struct partial_as_tuple
115118
{
116-
return as_tuple_t<decay_t<CompletionToken>>(
117-
static_cast<CompletionToken&&>(completion_token));
118-
}
119+
/// Default constructor.
120+
constexpr partial_as_tuple()
121+
{
122+
}
123+
124+
/// Adapt a @ref completion_token to specify that the completion handler
125+
/// arguments should be combined into a single tuple argument.
126+
template <typename CompletionToken>
127+
ASIO_NODISCARD inline
128+
constexpr as_tuple_t<decay_t<CompletionToken>>
129+
operator()(CompletionToken&& completion_token) const
130+
{
131+
return as_tuple_t<decay_t<CompletionToken>>(
132+
static_cast<CompletionToken&&>(completion_token));
133+
}
134+
};
135+
136+
/// A function object that adapts a @ref completion_token to specify that the
137+
/// completion handler arguments should be combined into a single tuple
138+
/// argument.
139+
/**
140+
* May also be used directly as a completion token, in which case it adapts the
141+
* asynchronous operation's default completion token (or asio::deferred
142+
* if no default is available).
143+
*/
144+
constexpr partial_as_tuple as_tuple;
119145

120146
} // namespace asio
121147

Diff for: example/vendor/cget/pkg/chriskohlhoff__asio/install/include/asio/associated_immediate_executor.hpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,10 @@ struct has_immediate_executor_type<T,
4949
template <typename E, typename = void, typename = void>
5050
struct default_immediate_executor
5151
{
52-
typedef require_result_t<E, execution::blocking_t::never_t> type;
52+
typedef decay_t<require_result_t<E, execution::blocking_t::never_t>> type;
5353

54-
static type get(const E& e) noexcept
54+
static auto get(const E& e) noexcept
55+
-> decltype(asio::require(e, execution::blocking.never))
5556
{
5657
return asio::require(e, execution::blocking.never);
5758
}

Diff for: example/vendor/cget/pkg/chriskohlhoff__asio/install/include/asio/associator.hpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ namespace asio {
2323

2424
/// Used to generically specialise associators for a type.
2525
template <template <typename, typename> class Associator,
26-
typename T, typename DefaultCandidate>
26+
typename T, typename DefaultCandidate, typename _ = void>
2727
struct associator
2828
{
2929
};

Diff for: example/vendor/cget/pkg/chriskohlhoff__asio/install/include/asio/async_result.hpp

+74-68
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,6 @@
2121
#include "asio/detail/push_options.hpp"
2222

2323
namespace asio {
24-
25-
#if defined(ASIO_HAS_CONCEPTS)
26-
2724
namespace detail {
2825

2926
template <typename T>
@@ -70,6 +67,12 @@ struct are_completion_signatures : false_type
7067
{
7168
};
7269

70+
template <>
71+
struct are_completion_signatures<>
72+
: true_type
73+
{
74+
};
75+
7376
template <typename T0>
7477
struct are_completion_signatures<T0>
7578
: is_completion_signature<T0>
@@ -84,6 +87,12 @@ struct are_completion_signatures<T0, TN...>
8487
{
8588
};
8689

90+
} // namespace detail
91+
92+
#if defined(ASIO_HAS_CONCEPTS)
93+
94+
namespace detail {
95+
8796
template <typename T, typename... Args>
8897
ASIO_CONCEPT callable_with = requires(T&& t, Args&&... args)
8998
{
@@ -606,14 +615,36 @@ template <typename CompletionToken,
606615
typename Initiation, typename... Args>
607616
inline auto async_initiate(Initiation&& initiation,
608617
type_identity_t<CompletionToken>& token, Args&&... args)
609-
-> constraint_t<
610-
detail::async_result_has_initiate_memfn<
611-
CompletionToken, Signatures...>::value,
612-
decltype(
613-
async_result<decay_t<CompletionToken>, Signatures...>::initiate(
614-
static_cast<Initiation&&>(initiation),
615-
static_cast<CompletionToken&&>(token),
616-
static_cast<Args&&>(args)...))>
618+
-> decltype(enable_if_t<
619+
enable_if_t<
620+
detail::are_completion_signatures<Signatures...>::value,
621+
detail::async_result_has_initiate_memfn<
622+
CompletionToken, Signatures...>>::value,
623+
async_result<decay_t<CompletionToken>, Signatures...>>::initiate(
624+
static_cast<Initiation&&>(initiation),
625+
static_cast<CompletionToken&&>(token),
626+
static_cast<Args&&>(args)...))
627+
{
628+
return async_result<decay_t<CompletionToken>, Signatures...>::initiate(
629+
static_cast<Initiation&&>(initiation),
630+
static_cast<CompletionToken&&>(token),
631+
static_cast<Args&&>(args)...);
632+
}
633+
634+
template <
635+
ASIO_COMPLETION_SIGNATURE... Signatures,
636+
typename CompletionToken, typename Initiation, typename... Args>
637+
inline auto async_initiate(Initiation&& initiation,
638+
CompletionToken&& token, Args&&... args)
639+
-> decltype(enable_if_t<
640+
enable_if_t<
641+
detail::are_completion_signatures<Signatures...>::value,
642+
detail::async_result_has_initiate_memfn<
643+
CompletionToken, Signatures...>>::value,
644+
async_result<decay_t<CompletionToken>, Signatures...>>::initiate(
645+
static_cast<Initiation&&>(initiation),
646+
static_cast<CompletionToken&&>(token),
647+
static_cast<Args&&>(args)...))
617648
{
618649
return async_result<decay_t<CompletionToken>, Signatures...>::initiate(
619650
static_cast<Initiation&&>(initiation),
@@ -624,10 +655,13 @@ inline auto async_initiate(Initiation&& initiation,
624655
template <typename CompletionToken,
625656
ASIO_COMPLETION_SIGNATURE... Signatures,
626657
typename Initiation, typename... Args>
627-
inline constraint_t<
628-
!detail::async_result_has_initiate_memfn<
629-
CompletionToken, Signatures...>::value,
630-
typename async_result<decay_t<CompletionToken>, Signatures...>::return_type>
658+
inline typename enable_if_t<
659+
!enable_if_t<
660+
detail::are_completion_signatures<Signatures...>::value,
661+
detail::async_result_has_initiate_memfn<
662+
CompletionToken, Signatures...>>::value,
663+
async_result<decay_t<CompletionToken>, Signatures...>
664+
>::return_type
631665
async_initiate(Initiation&& initiation,
632666
type_identity_t<CompletionToken>& token, Args&&... args)
633667
{
@@ -643,6 +677,29 @@ async_initiate(Initiation&& initiation,
643677
return completion.result.get();
644678
}
645679

680+
template <ASIO_COMPLETION_SIGNATURE... Signatures,
681+
typename CompletionToken, typename Initiation, typename... Args>
682+
inline typename enable_if_t<
683+
!enable_if_t<
684+
detail::are_completion_signatures<Signatures...>::value,
685+
detail::async_result_has_initiate_memfn<
686+
CompletionToken, Signatures...>>::value,
687+
async_result<decay_t<CompletionToken>, Signatures...>
688+
>::return_type
689+
async_initiate(Initiation&& initiation, CompletionToken&& token, Args&&... args)
690+
{
691+
async_completion<CompletionToken, Signatures...> completion(token);
692+
693+
static_cast<Initiation&&>(initiation)(
694+
static_cast<
695+
typename async_result<decay_t<CompletionToken>,
696+
Signatures...>::completion_handler_type&&>(
697+
completion.completion_handler),
698+
static_cast<Args&&>(args)...);
699+
700+
return completion.result.get();
701+
}
702+
646703
#endif // defined(GENERATING_DOCUMENTATION)
647704

648705
#if defined(ASIO_HAS_CONCEPTS)
@@ -882,61 +939,10 @@ template <typename T, typename... Args>
882939
using completion_signature_of_t =
883940
typename completion_signature_of<T, Args...>::type;
884941

885-
namespace detail {
886-
887-
template <typename T, typename = void>
888-
struct default_completion_token_impl
889-
{
890-
typedef void type;
891-
};
892-
893-
template <typename T>
894-
struct default_completion_token_impl<T,
895-
void_t<typename T::default_completion_token_type>
896-
>
897-
{
898-
typedef typename T::default_completion_token_type type;
899-
};
900-
901-
} // namespace detail
902-
903-
#if defined(GENERATING_DOCUMENTATION)
904-
905-
/// Traits type used to determine the default completion token type associated
906-
/// with a type (such as an executor).
907-
/**
908-
* A program may specialise this traits type if the @c T template parameter in
909-
* the specialisation is a user-defined type.
910-
*
911-
* Specialisations of this trait may provide a nested typedef @c type, which is
912-
* a default-constructible completion token type.
913-
*/
914-
template <typename T>
915-
struct default_completion_token
916-
{
917-
/// If @c T has a nested type @c default_completion_token_type,
918-
/// <tt>T::default_completion_token_type</tt>. Otherwise the typedef @c type
919-
/// is not defined.
920-
typedef see_below type;
921-
};
922-
#else
923-
template <typename T>
924-
struct default_completion_token
925-
: detail::default_completion_token_impl<T>
926-
{
927-
};
928-
#endif
929-
930-
template <typename T>
931-
using default_completion_token_t = typename default_completion_token<T>::type;
932-
933-
#define ASIO_DEFAULT_COMPLETION_TOKEN_TYPE(e) \
934-
= typename ::asio::default_completion_token<e>::type
935-
#define ASIO_DEFAULT_COMPLETION_TOKEN(e) \
936-
= typename ::asio::default_completion_token<e>::type()
937-
938942
} // namespace asio
939943

940944
#include "asio/detail/pop_options.hpp"
941945

946+
#include "asio/default_completion_token.hpp"
947+
942948
#endif // ASIO_ASYNC_RESULT_HPP

Diff for: example/vendor/cget/pkg/chriskohlhoff__asio/install/include/asio/basic_datagram_socket.hpp

+11-11
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ class basic_datagram_socket
447447
* Regardless of whether the asynchronous operation completes immediately or
448448
* not, the completion handler will not be invoked from within this function.
449449
* On immediate completion, invocation of the handler will be performed in a
450-
* manner equivalent to using asio::post().
450+
* manner equivalent to using asio::async_immediate().
451451
*
452452
* @par Completion Signature
453453
* @code void(asio::error_code, std::size_t) @endcode
@@ -517,7 +517,7 @@ class basic_datagram_socket
517517
* Regardless of whether the asynchronous operation completes immediately or
518518
* not, the completion handler will not be invoked from within this function.
519519
* On immediate completion, invocation of the handler will be performed in a
520-
* manner equivalent to using asio::post().
520+
* manner equivalent to using asio::async_immediate().
521521
*
522522
* @par Completion Signature
523523
* @code void(asio::error_code, std::size_t) @endcode
@@ -666,7 +666,7 @@ class basic_datagram_socket
666666
* Regardless of whether the asynchronous operation completes immediately or
667667
* not, the completion handler will not be invoked from within this function.
668668
* On immediate completion, invocation of the handler will be performed in a
669-
* manner equivalent to using asio::post().
669+
* manner equivalent to using asio::async_immediate().
670670
*
671671
* @par Completion Signature
672672
* @code void(asio::error_code, std::size_t) @endcode
@@ -739,7 +739,7 @@ class basic_datagram_socket
739739
* Regardless of whether the asynchronous operation completes immediately or
740740
* not, the completion handler will not be invoked from within this function.
741741
* On immediate completion, invocation of the handler will be performed in a
742-
* manner equivalent to using asio::post().
742+
* manner equivalent to using asio::async_immediate().
743743
*
744744
* @par Completion Signature
745745
* @code void(asio::error_code, std::size_t) @endcode
@@ -884,7 +884,7 @@ class basic_datagram_socket
884884
* Regardless of whether the asynchronous operation completes immediately or
885885
* not, the completion handler will not be invoked from within this function.
886886
* On immediate completion, invocation of the handler will be performed in a
887-
* manner equivalent to using asio::post().
887+
* manner equivalent to using asio::async_immediate().
888888
*
889889
* @par Completion Signature
890890
* @code void(asio::error_code, std::size_t) @endcode
@@ -955,7 +955,7 @@ class basic_datagram_socket
955955
* Regardless of whether the asynchronous operation completes immediately or
956956
* not, the completion handler will not be invoked from within this function.
957957
* On immediate completion, invocation of the handler will be performed in a
958-
* manner equivalent to using asio::post().
958+
* manner equivalent to using asio::async_immediate().
959959
*
960960
* @par Completion Signature
961961
* @code void(asio::error_code, std::size_t) @endcode
@@ -1026,7 +1026,7 @@ class basic_datagram_socket
10261026
asio::detail::throw_error(ec, "receive_from");
10271027
return s;
10281028
}
1029-
1029+
10301030
/// Receive a datagram with the endpoint of the sender.
10311031
/**
10321032
* This function is used to receive a datagram. The function call will block
@@ -1053,7 +1053,7 @@ class basic_datagram_socket
10531053
asio::detail::throw_error(ec, "receive_from");
10541054
return s;
10551055
}
1056-
1056+
10571057
/// Receive a datagram with the endpoint of the sender.
10581058
/**
10591059
* This function is used to receive a datagram. The function call will block
@@ -1107,7 +1107,7 @@ class basic_datagram_socket
11071107
* Regardless of whether the asynchronous operation completes immediately or
11081108
* not, the completion handler will not be invoked from within this function.
11091109
* On immediate completion, invocation of the handler will be performed in a
1110-
* manner equivalent to using asio::post().
1110+
* manner equivalent to using asio::async_immediate().
11111111
*
11121112
* @par Completion Signature
11131113
* @code void(asio::error_code, std::size_t) @endcode
@@ -1179,7 +1179,7 @@ class basic_datagram_socket
11791179
* Regardless of whether the asynchronous operation completes immediately or
11801180
* not, the completion handler will not be invoked from within this function.
11811181
* On immediate completion, invocation of the handler will be performed in a
1182-
* manner equivalent to using asio::post().
1182+
* manner equivalent to using asio::async_immediate().
11831183
*
11841184
* @par Completion Signature
11851185
* @code void(asio::error_code, std::size_t) @endcode
@@ -1219,7 +1219,7 @@ class basic_datagram_socket
12191219
const basic_datagram_socket&) = delete;
12201220

12211221
class initiate_async_send
1222-
{
1222+
{
12231223
public:
12241224
typedef Executor executor_type;
12251225

0 commit comments

Comments
 (0)