From 5f6fe55d5c10da013ad4790a49e8a6b9840247e5 Mon Sep 17 00:00:00 2001 From: Philipp Bucher Date: Sat, 9 Sep 2023 23:18:04 +0300 Subject: [PATCH] Several updates (#353) * update py-versions * revert * comment C tests * update pybind to 2.11.1 * update Asio to 1.28 * using newer centos image * update changelog * minor in CI * update version --- .github/workflows/ci.yml | 14 +- CHANGELOG.md | 5 + co_sim_io/sources/version.cpp | 2 +- external_libraries/asio/COPYING | 2 +- external_libraries/asio/README | 4 +- external_libraries/asio/include/Makefile.am | 111 +- external_libraries/asio/include/Makefile.in | 126 +- external_libraries/asio/include/asio.hpp | 32 +- .../include/asio/any_completion_executor.hpp | 342 +++ .../include/asio/any_completion_handler.hpp | 762 ++++++ .../asio/include/asio/any_io_executor.hpp | 135 +- .../asio/include/asio/append.hpp | 78 + .../asio/include/asio/as_tuple.hpp | 139 ++ .../include/asio/associated_allocator.hpp | 112 +- .../asio/associated_cancellation_slot.hpp | 79 +- .../asio/include/asio/associated_executor.hpp | 57 +- .../asio/associated_immediate_executor.hpp | 297 +++ .../asio/include/asio/associator.hpp | 2 +- .../asio/include/asio/async_result.hpp | 408 +++- .../asio/include/asio/awaitable.hpp | 11 +- .../include/asio/basic_datagram_socket.hpp | 331 ++- .../include/asio/basic_deadline_timer.hpp | 48 +- .../asio/include/asio/basic_file.hpp | 829 +++++++ .../asio/include/asio/basic_io_object.hpp | 2 +- .../include/asio/basic_random_access_file.hpp | 701 ++++++ .../asio/include/asio/basic_raw_socket.hpp | 335 ++- .../asio/include/asio/basic_readable_pipe.hpp | 635 +++++ .../include/asio/basic_seq_packet_socket.hpp | 135 +- .../asio/include/asio/basic_serial_port.hpp | 159 +- .../asio/include/asio/basic_signal_set.hpp | 109 +- .../asio/include/asio/basic_socket.hpp | 90 +- .../include/asio/basic_socket_acceptor.hpp | 469 ++-- .../include/asio/basic_socket_iostream.hpp | 2 +- .../include/asio/basic_socket_streambuf.hpp | 2 +- .../asio/include/asio/basic_stream_file.hpp | 754 ++++++ .../asio/include/asio/basic_stream_socket.hpp | 241 +- .../asio/include/asio/basic_streambuf.hpp | 2 +- .../asio/include/asio/basic_streambuf_fwd.hpp | 2 +- .../include/asio/basic_waitable_timer.hpp | 48 +- .../asio/include/asio/basic_writable_pipe.hpp | 631 +++++ .../asio/include/asio/bind_allocator.hpp | 733 ++++++ .../include/asio/bind_cancellation_slot.hpp | 39 +- .../asio/include/asio/bind_executor.hpp | 75 +- .../include/asio/bind_immediate_executor.hpp | 736 ++++++ .../asio/include/asio/buffer.hpp | 497 +++- .../asio/include/asio/buffer_registration.hpp | 328 +++ .../include/asio/buffered_read_stream.hpp | 53 +- .../include/asio/buffered_read_stream_fwd.hpp | 2 +- .../asio/include/asio/buffered_stream.hpp | 49 +- .../asio/include/asio/buffered_stream_fwd.hpp | 2 +- .../include/asio/buffered_write_stream.hpp | 53 +- .../asio/buffered_write_stream_fwd.hpp | 2 +- .../asio/include/asio/buffers_iterator.hpp | 2 +- .../asio/include/asio/cancellation_signal.hpp | 74 +- .../asio/include/asio/cancellation_state.hpp | 2 +- .../asio/include/asio/cancellation_type.hpp | 2 +- .../asio/include/asio/co_spawn.hpp | 42 +- .../include/asio/completion_condition.hpp | 2 +- .../asio/include/asio/compose.hpp | 421 +++- .../asio/include/asio/connect.hpp | 193 +- .../asio/include/asio/connect_pipe.hpp | 83 + .../asio/include/asio/consign.hpp | 88 + .../asio/include/asio/coroutine.hpp | 2 +- .../asio/include/asio/deadline_timer.hpp | 2 +- .../asio/include/asio/defer.hpp | 182 +- .../asio/include/asio/deferred.hpp | 802 +++++++ .../asio/include/asio/detached.hpp | 11 +- .../asio/include/asio/detail/array.hpp | 2 +- .../asio/include/asio/detail/array_fwd.hpp | 2 +- .../asio/include/asio/detail/assert.hpp | 2 +- .../asio/include/asio/detail/atomic_count.hpp | 5 +- .../detail/base_from_cancellation_state.hpp | 2 +- .../asio/detail/base_from_completion_cond.hpp | 2 +- .../asio/include/asio/detail/bind_handler.hpp | 124 +- .../asio/detail/blocking_executor_op.hpp | 3 +- .../asio/detail/buffer_resize_guard.hpp | 2 +- .../asio/detail/buffer_sequence_adapter.hpp | 193 +- .../asio/detail/buffered_stream_storage.hpp | 2 +- .../include/asio/detail/bulk_executor_op.hpp | 3 +- .../asio/include/asio/detail/call_stack.hpp | 2 +- .../asio/include/asio/detail/chrono.hpp | 2 +- .../asio/detail/chrono_time_traits.hpp | 2 +- .../asio/detail/completion_handler.hpp | 2 +- .../include/asio/detail/composed_work.hpp | 328 +++ .../include/asio/detail/concurrency_hint.hpp | 2 +- .../detail/conditionally_enabled_event.hpp | 2 +- .../detail/conditionally_enabled_mutex.hpp | 2 +- .../asio/include/asio/detail/config.hpp | 391 +++- .../include/asio/detail/consuming_buffers.hpp | 39 +- .../asio/include/asio/detail/cstddef.hpp | 2 +- .../asio/include/asio/detail/cstdint.hpp | 4 +- .../include/asio/detail/date_time_fwd.hpp | 2 +- .../asio/detail/deadline_timer_service.hpp | 2 +- .../include/asio/detail/dependent_type.hpp | 2 +- .../include/asio/detail/descriptor_ops.hpp | 44 +- .../asio/detail/descriptor_read_op.hpp | 42 +- .../asio/detail/descriptor_write_op.hpp | 41 +- .../include/asio/detail/dev_poll_reactor.hpp | 34 +- .../include/asio/detail/epoll_reactor.hpp | 27 +- .../asio/include/asio/detail/event.hpp | 2 +- .../detail/eventfd_select_interrupter.hpp | 2 +- .../asio/include/asio/detail/exception.hpp | 40 + .../include/asio/detail/executor_function.hpp | 2 +- .../asio/include/asio/detail/executor_op.hpp | 3 +- .../include/asio/detail/fd_set_adapter.hpp | 2 +- .../asio/include/asio/detail/fenced_block.hpp | 2 +- .../asio/include/asio/detail/functional.hpp | 2 +- .../asio/include/asio/detail/future.hpp | 2 +- .../asio/detail/gcc_arm_fenced_block.hpp | 2 +- .../asio/detail/gcc_hppa_fenced_block.hpp | 2 +- .../asio/detail/gcc_sync_fenced_block.hpp | 2 +- .../asio/detail/gcc_x86_fenced_block.hpp | 4 +- .../asio/include/asio/detail/global.hpp | 2 +- .../asio/detail/handler_alloc_helpers.hpp | 10 +- .../asio/detail/handler_cont_helpers.hpp | 2 +- .../asio/detail/handler_invoke_helpers.hpp | 2 +- .../include/asio/detail/handler_tracking.hpp | 2 +- .../asio/detail/handler_type_requirements.hpp | 2 +- .../asio/include/asio/detail/handler_work.hpp | 64 +- .../asio/include/asio/detail/hash_map.hpp | 2 +- .../detail/impl/buffer_sequence_adapter.ipp | 2 +- .../asio/detail/impl/descriptor_ops.ipp | 372 ++- .../asio/detail/impl/dev_poll_reactor.hpp | 16 +- .../asio/detail/impl/dev_poll_reactor.ipp | 17 +- .../asio/detail/impl/epoll_reactor.hpp | 4 +- .../asio/detail/impl/epoll_reactor.ipp | 25 +- .../impl/eventfd_select_interrupter.ipp | 2 +- .../asio/detail/impl/handler_tracking.ipp | 6 +- .../impl/io_uring_descriptor_service.ipp | 205 ++ .../detail/impl/io_uring_file_service.ipp | 140 ++ .../asio/detail/impl/io_uring_service.hpp | 112 + .../asio/detail/impl/io_uring_service.ipp | 909 +++++++ .../impl/io_uring_socket_service_base.ipp | 249 ++ .../asio/detail/impl/kqueue_reactor.hpp | 4 +- .../asio/detail/impl/kqueue_reactor.ipp | 21 +- .../include/asio/detail/impl/null_event.ipp | 2 +- .../detail/impl/pipe_select_interrupter.ipp | 2 +- .../include/asio/detail/impl/posix_event.ipp | 2 +- .../include/asio/detail/impl/posix_mutex.ipp | 2 +- ...vice.ipp => posix_serial_port_service.ipp} | 57 +- .../include/asio/detail/impl/posix_thread.ipp | 2 +- .../asio/detail/impl/posix_tss_ptr.ipp | 2 +- .../impl/reactive_descriptor_service.ipp | 25 +- .../impl/reactive_socket_service_base.ipp | 48 +- .../detail/impl/resolver_service_base.ipp | 2 +- .../include/asio/detail/impl/scheduler.ipp | 24 +- .../asio/detail/impl/select_reactor.hpp | 4 +- .../asio/detail/impl/select_reactor.ipp | 53 +- .../asio/detail/impl/service_registry.hpp | 2 +- .../asio/detail/impl/service_registry.ipp | 2 +- .../asio/detail/impl/signal_set_service.ipp | 168 +- .../include/asio/detail/impl/socket_ops.ipp | 259 +- .../detail/impl/socket_select_interrupter.ipp | 8 +- .../detail/impl/strand_executor_service.hpp | 17 +- .../detail/impl/strand_executor_service.ipp | 2 +- .../asio/detail/impl/strand_service.hpp | 2 +- .../asio/detail/impl/strand_service.ipp | 2 +- .../asio/detail/impl/thread_context.ipp | 2 +- .../include/asio/detail/impl/throw_error.ipp | 22 +- .../asio/detail/impl/timer_queue_ptime.ipp | 2 +- .../asio/detail/impl/timer_queue_set.ipp | 2 +- .../include/asio/detail/impl/win_event.ipp | 2 +- .../detail/impl/win_iocp_file_service.ipp | 265 +++ .../detail/impl/win_iocp_handle_service.ipp | 96 +- .../asio/detail/impl/win_iocp_io_context.hpp | 2 +- .../asio/detail/impl/win_iocp_io_context.ipp | 11 +- .../impl/win_iocp_serial_port_service.ipp | 10 +- .../impl/win_iocp_socket_service_base.ipp | 22 +- .../include/asio/detail/impl/win_mutex.ipp | 2 +- .../detail/impl/win_object_handle_service.ipp | 6 +- .../asio/detail/impl/win_static_mutex.ipp | 2 +- .../include/asio/detail/impl/win_thread.ipp | 2 +- .../include/asio/detail/impl/win_tss_ptr.ipp | 2 +- .../impl/winrt_ssocket_service_base.ipp | 8 +- .../detail/impl/winrt_timer_scheduler.hpp | 2 +- .../detail/impl/winrt_timer_scheduler.ipp | 2 +- .../include/asio/detail/impl/winsock_init.ipp | 2 +- .../defer.hpp => detail/initiate_defer.hpp} | 76 +- .../initiate_dispatch.hpp} | 76 +- .../post.hpp => detail/initiate_post.hpp} | 76 +- .../asio/include/asio/detail/io_control.hpp | 2 +- .../include/asio/detail/io_object_impl.hpp | 13 +- .../detail/io_uring_descriptor_read_at_op.hpp | 195 ++ .../detail/io_uring_descriptor_read_op.hpp | 190 ++ .../detail/io_uring_descriptor_service.hpp | 687 ++++++ .../io_uring_descriptor_write_at_op.hpp | 189 ++ .../detail/io_uring_descriptor_write_op.hpp | 185 ++ .../asio/detail/io_uring_file_service.hpp | 261 +++ .../asio/detail/io_uring_null_buffers_op.hpp | 115 + .../asio/detail/io_uring_operation.hpp | 84 + .../include/asio/detail/io_uring_service.hpp | 319 +++ .../asio/detail/io_uring_socket_accept_op.hpp | 285 +++ .../detail/io_uring_socket_connect_op.hpp | 141 ++ .../asio/detail/io_uring_socket_recv_op.hpp | 205 ++ .../detail/io_uring_socket_recvfrom_op.hpp | 206 ++ .../detail/io_uring_socket_recvmsg_op.hpp | 192 ++ .../asio/detail/io_uring_socket_send_op.hpp | 191 ++ .../asio/detail/io_uring_socket_sendto_op.hpp | 194 ++ .../asio/detail/io_uring_socket_service.hpp | 631 +++++ .../detail/io_uring_socket_service_base.hpp | 663 ++++++ .../include/asio/detail/io_uring_wait_op.hpp | 113 + .../asio/detail/is_buffer_sequence.hpp | 28 +- .../asio/include/asio/detail/is_executor.hpp | 2 +- .../include/asio/detail/keyword_tss_ptr.hpp | 2 +- .../include/asio/detail/kqueue_reactor.hpp | 27 +- .../asio/detail/local_free_on_block_exit.hpp | 2 +- .../asio/detail/macos_fenced_block.hpp | 2 +- .../asio/include/asio/detail/memory.hpp | 36 +- .../asio/include/asio/detail/mutex.hpp | 2 +- .../include/asio/detail/non_const_lvalue.hpp | 2 +- .../asio/include/asio/detail/noncopyable.hpp | 2 +- .../asio/include/asio/detail/null_event.hpp | 2 +- .../include/asio/detail/null_fenced_block.hpp | 2 +- .../asio/include/asio/detail/null_global.hpp | 2 +- .../asio/include/asio/detail/null_mutex.hpp | 6 +- .../asio/include/asio/detail/null_reactor.hpp | 23 +- .../asio/detail/null_signal_blocker.hpp | 2 +- .../asio/detail/null_socket_service.hpp | 2 +- .../include/asio/detail/null_static_mutex.hpp | 2 +- .../asio/include/asio/detail/null_thread.hpp | 2 +- .../asio/include/asio/detail/null_tss_ptr.hpp | 2 +- .../asio/include/asio/detail/object_pool.hpp | 2 +- .../asio/detail/old_win_sdk_compat.hpp | 2 +- .../asio/include/asio/detail/op_queue.hpp | 2 +- .../asio/include/asio/detail/operation.hpp | 2 +- .../asio/detail/pipe_select_interrupter.hpp | 2 +- .../asio/include/asio/detail/pop_options.hpp | 10 +- .../asio/include/asio/detail/posix_event.hpp | 2 +- .../asio/detail/posix_fd_set_adapter.hpp | 2 +- .../asio/include/asio/detail/posix_global.hpp | 2 +- .../asio/include/asio/detail/posix_mutex.hpp | 2 +- ...vice.hpp => posix_serial_port_service.hpp} | 48 +- .../asio/detail/posix_signal_blocker.hpp | 2 +- .../asio/detail/posix_static_mutex.hpp | 2 +- .../asio/include/asio/detail/posix_thread.hpp | 2 +- .../include/asio/detail/posix_tss_ptr.hpp | 2 +- .../asio/include/asio/detail/push_options.hpp | 14 +- .../detail/reactive_descriptor_service.hpp | 109 +- .../asio/detail/reactive_null_buffers_op.hpp | 36 +- .../asio/detail/reactive_socket_accept_op.hpp | 88 +- .../detail/reactive_socket_connect_op.hpp | 42 +- .../asio/detail/reactive_socket_recv_op.hpp | 41 +- .../detail/reactive_socket_recvfrom_op.hpp | 42 +- .../detail/reactive_socket_recvmsg_op.hpp | 42 +- .../asio/detail/reactive_socket_send_op.hpp | 42 +- .../asio/detail/reactive_socket_sendto_op.hpp | 41 +- .../asio/detail/reactive_socket_service.hpp | 70 +- .../detail/reactive_socket_service_base.hpp | 158 +- .../include/asio/detail/reactive_wait_op.hpp | 36 +- .../asio/include/asio/detail/reactor.hpp | 32 +- .../asio/include/asio/detail/reactor_fwd.hpp | 40 - .../asio/include/asio/detail/reactor_op.hpp | 2 +- .../include/asio/detail/reactor_op_queue.hpp | 2 +- .../asio/detail/recycling_allocator.hpp | 2 +- .../asio/include/asio/detail/regex_fwd.hpp | 2 +- .../asio/detail/resolve_endpoint_op.hpp | 3 +- .../asio/include/asio/detail/resolve_op.hpp | 2 +- .../include/asio/detail/resolve_query_op.hpp | 3 +- .../include/asio/detail/resolver_service.hpp | 4 +- .../asio/detail/resolver_service_base.hpp | 2 +- .../asio/include/asio/detail/scheduler.hpp | 20 +- .../asio/detail/scheduler_operation.hpp | 2 +- .../include/asio/detail/scheduler_task.hpp | 49 + .../asio/detail/scheduler_thread_info.hpp | 2 +- .../asio/include/asio/detail/scoped_lock.hpp | 2 +- .../asio/include/asio/detail/scoped_ptr.hpp | 2 +- .../asio/detail/select_interrupter.hpp | 2 +- .../include/asio/detail/select_reactor.hpp | 49 +- .../include/asio/detail/service_registry.hpp | 2 +- .../include/asio/detail/signal_blocker.hpp | 2 +- .../include/asio/detail/signal_handler.hpp | 2 +- .../asio/include/asio/detail/signal_init.hpp | 2 +- .../asio/include/asio/detail/signal_op.hpp | 6 +- .../asio/detail/signal_set_service.hpp | 71 +- .../include/asio/detail/socket_holder.hpp | 2 +- .../asio/include/asio/detail/socket_ops.hpp | 82 +- .../include/asio/detail/socket_option.hpp | 2 +- .../asio/detail/socket_select_interrupter.hpp | 2 +- .../asio/include/asio/detail/socket_types.hpp | 12 +- .../asio/detail/solaris_fenced_block.hpp | 2 +- .../include/asio/detail/source_location.hpp | 2 +- .../asio/include/asio/detail/static_mutex.hpp | 2 +- .../asio/include/asio/detail/std_event.hpp | 2 +- .../include/asio/detail/std_fenced_block.hpp | 2 +- .../asio/include/asio/detail/std_global.hpp | 2 +- .../asio/include/asio/detail/std_mutex.hpp | 2 +- .../include/asio/detail/std_static_mutex.hpp | 2 +- .../asio/include/asio/detail/std_thread.hpp | 2 +- .../asio/detail/strand_executor_service.hpp | 2 +- .../include/asio/detail/strand_service.hpp | 2 +- .../asio/include/asio/detail/string_view.hpp | 2 +- .../asio/include/asio/detail/thread.hpp | 2 +- .../include/asio/detail/thread_context.hpp | 2 +- .../asio/include/asio/detail/thread_group.hpp | 2 +- .../include/asio/detail/thread_info_base.hpp | 6 +- .../asio/include/asio/detail/throw_error.hpp | 27 +- .../include/asio/detail/throw_exception.hpp | 10 +- .../asio/include/asio/detail/timer_queue.hpp | 2 +- .../include/asio/detail/timer_queue_base.hpp | 2 +- .../include/asio/detail/timer_queue_ptime.hpp | 2 +- .../include/asio/detail/timer_queue_set.hpp | 2 +- .../include/asio/detail/timer_scheduler.hpp | 4 +- .../asio/detail/timer_scheduler_fwd.hpp | 4 +- .../asio/include/asio/detail/tss_ptr.hpp | 2 +- .../asio/include/asio/detail/type_traits.hpp | 10 +- .../asio/include/asio/detail/utility.hpp | 83 + .../asio/detail/variadic_templates.hpp | 2 +- .../asio/include/asio/detail/wait_handler.hpp | 2 +- .../asio/include/asio/detail/wait_op.hpp | 2 +- .../asio/include/asio/detail/win_event.hpp | 2 +- .../asio/detail/win_fd_set_adapter.hpp | 2 +- .../include/asio/detail/win_fenced_block.hpp | 2 +- .../asio/include/asio/detail/win_global.hpp | 2 +- .../asio/detail/win_iocp_file_service.hpp | 287 +++ .../asio/detail/win_iocp_handle_read_op.hpp | 5 +- .../asio/detail/win_iocp_handle_service.hpp | 30 +- .../asio/detail/win_iocp_handle_write_op.hpp | 9 +- .../asio/detail/win_iocp_io_context.hpp | 4 +- .../asio/detail/win_iocp_null_buffers_op.hpp | 5 +- .../asio/detail/win_iocp_operation.hpp | 2 +- .../asio/detail/win_iocp_overlapped_op.hpp | 9 +- .../asio/detail/win_iocp_overlapped_ptr.hpp | 2 +- .../detail/win_iocp_serial_port_service.hpp | 3 +- .../asio/detail/win_iocp_socket_accept_op.hpp | 10 +- .../detail/win_iocp_socket_connect_op.hpp | 6 +- .../asio/detail/win_iocp_socket_recv_op.hpp | 5 +- .../detail/win_iocp_socket_recvfrom_op.hpp | 5 +- .../detail/win_iocp_socket_recvmsg_op.hpp | 5 +- .../asio/detail/win_iocp_socket_send_op.hpp | 5 +- .../asio/detail/win_iocp_socket_service.hpp | 40 +- .../detail/win_iocp_socket_service_base.hpp | 14 +- .../asio/detail/win_iocp_thread_info.hpp | 2 +- .../include/asio/detail/win_iocp_wait_op.hpp | 5 +- .../asio/include/asio/detail/win_mutex.hpp | 2 +- .../asio/detail/win_object_handle_service.hpp | 2 +- .../include/asio/detail/win_static_mutex.hpp | 2 +- .../asio/include/asio/detail/win_thread.hpp | 2 +- .../asio/include/asio/detail/win_tss_ptr.hpp | 2 +- .../include/asio/detail/winapp_thread.hpp | 2 +- .../asio/include/asio/detail/wince_thread.hpp | 2 +- .../asio/detail/winrt_async_manager.hpp | 2 +- .../include/asio/detail/winrt_async_op.hpp | 2 +- .../include/asio/detail/winrt_resolve_op.hpp | 3 +- .../asio/detail/winrt_resolver_service.hpp | 2 +- .../asio/detail/winrt_socket_connect_op.hpp | 3 +- .../asio/detail/winrt_socket_recv_op.hpp | 3 +- .../asio/detail/winrt_socket_send_op.hpp | 3 +- .../asio/detail/winrt_ssocket_service.hpp | 2 +- .../detail/winrt_ssocket_service_base.hpp | 2 +- .../asio/detail/winrt_timer_scheduler.hpp | 2 +- .../asio/include/asio/detail/winrt_utils.hpp | 2 +- .../asio/include/asio/detail/winsock_init.hpp | 2 +- .../include/asio/detail/work_dispatcher.hpp | 14 +- .../include/asio/detail/wrapped_handler.hpp | 2 +- .../asio/include/asio/dispatch.hpp | 165 +- .../asio/include/asio/error.hpp | 37 +- .../asio/include/asio/error_code.hpp | 2 +- .../asio/include/asio/execution.hpp | 2 +- .../asio/include/asio/execution/allocator.hpp | 27 +- .../include/asio/execution/any_executor.hpp | 611 +++-- .../include/asio/execution/bad_executor.hpp | 2 +- .../asio/include/asio/execution/blocking.hpp | 67 +- .../asio/execution/blocking_adaptation.hpp | 59 +- .../include/asio/execution/bulk_execute.hpp | 7 +- .../include/asio/execution/bulk_guarantee.hpp | 47 +- .../asio/include/asio/execution/connect.hpp | 7 +- .../asio/include/asio/execution/context.hpp | 17 +- .../include/asio/execution/context_as.hpp | 17 +- .../asio/execution/detail/as_invocable.hpp | 2 +- .../asio/execution/detail/as_operation.hpp | 6 +- .../asio/execution/detail/as_receiver.hpp | 2 +- .../asio/execution/detail/bulk_sender.hpp | 2 +- .../asio/execution/detail/submit_receiver.hpp | 2 +- .../asio/execution/detail/void_receiver.hpp | 2 +- .../asio/include/asio/execution/execute.hpp | 13 +- .../asio/include/asio/execution/executor.hpp | 14 +- .../asio/execution/impl/bad_executor.ipp | 2 +- .../impl/receiver_invocation_error.ipp | 2 +- .../asio/execution/invocable_archetype.hpp | 2 +- .../asio/include/asio/execution/mapping.hpp | 62 +- .../asio/include/asio/execution/occupancy.hpp | 17 +- .../asio/execution/operation_state.hpp | 7 +- .../asio/execution/outstanding_work.hpp | 47 +- .../include/asio/execution/prefer_only.hpp | 2 +- .../asio/include/asio/execution/receiver.hpp | 7 +- .../execution/receiver_invocation_error.hpp | 2 +- .../include/asio/execution/relationship.hpp | 47 +- .../asio/include/asio/execution/schedule.hpp | 7 +- .../asio/include/asio/execution/scheduler.hpp | 7 +- .../asio/include/asio/execution/sender.hpp | 7 +- .../asio/include/asio/execution/set_done.hpp | 7 +- .../asio/include/asio/execution/set_error.hpp | 7 +- .../asio/include/asio/execution/set_value.hpp | 7 +- .../asio/include/asio/execution/start.hpp | 7 +- .../asio/include/asio/execution/submit.hpp | 7 +- .../asio/include/asio/execution_context.hpp | 2 +- .../asio/include/asio/executor.hpp | 2 +- .../asio/include/asio/executor_work_guard.hpp | 145 +- .../asio/include/asio/experimental/append.hpp | 47 +- .../include/asio/experimental/as_single.hpp | 11 +- .../include/asio/experimental/as_tuple.hpp | 107 +- .../asio/experimental/awaitable_operators.hpp | 28 +- .../asio/experimental/basic_channel.hpp | 491 ++++ .../experimental/basic_concurrent_channel.hpp | 491 ++++ .../experimental/cancellation_condition.hpp | 2 +- .../include/asio/experimental/channel.hpp | 70 + .../asio/experimental/channel_error.hpp | 84 + .../asio/experimental/channel_traits.hpp | 301 +++ .../include/asio/experimental/co_composed.hpp | 144 ++ .../include/asio/experimental/co_spawn.hpp | 187 ++ .../asio/experimental/concurrent_channel.hpp | 70 + .../asio/include/asio/experimental/coro.hpp | 1014 +------- .../experimental/{detail => }/coro_traits.hpp | 85 +- .../include/asio/experimental/deferred.hpp | 581 +---- .../experimental/detail/channel_handler.hpp | 80 + .../experimental/detail/channel_message.hpp | 129 + .../experimental/detail/channel_operation.hpp | 284 +++ .../experimental/detail/channel_payload.hpp | 139 ++ .../detail/channel_receive_op.hpp | 120 + .../detail/channel_send_functions.hpp | 144 ++ .../experimental/detail/channel_send_op.hpp | 148 ++ .../experimental/detail/channel_service.hpp | 677 ++++++ .../detail/completion_handler_erasure.hpp | 158 -- .../detail/coro_completion_handler.hpp | 169 ++ .../detail/coro_promise_allocator.hpp | 161 +- .../experimental/detail/has_signature.hpp | 54 + .../detail/impl/channel_service.hpp | 612 +++++ .../experimental/detail/partial_promise.hpp | 118 +- .../asio/experimental/impl/as_single.hpp | 18 +- .../asio/experimental/impl/channel_error.ipp | 61 + .../asio/experimental/impl/co_composed.hpp | 1175 ++++++++++ .../include/asio/experimental/impl/coro.hpp | 1222 ++++++++++ .../asio/experimental/impl/deferred.hpp | 104 - .../asio/experimental/impl/parallel_group.hpp | 414 +++- .../asio/experimental/impl/promise.hpp | 218 +- .../asio/experimental/impl/use_coro.hpp | 214 ++ .../asio/experimental/impl/use_promise.hpp | 66 + .../asio/experimental/parallel_group.hpp | 320 ++- .../include/asio/experimental/prepend.hpp | 47 +- .../include/asio/experimental/promise.hpp | 554 +---- .../include/asio/experimental/use_coro.hpp | 369 ++- .../include/asio/experimental/use_promise.hpp | 111 + .../asio/include/asio/file_base.hpp | 166 ++ .../include/asio/generic/basic_endpoint.hpp | 2 +- .../asio/generic/datagram_protocol.hpp | 2 +- .../include/asio/generic/detail/endpoint.hpp | 2 +- .../asio/generic/detail/impl/endpoint.ipp | 2 +- .../include/asio/generic/raw_protocol.hpp | 2 +- .../asio/generic/seq_packet_protocol.hpp | 2 +- .../include/asio/generic/stream_protocol.hpp | 2 +- .../asio/include/asio/handler_alloc_hook.hpp | 2 +- .../asio/handler_continuation_hook.hpp | 2 +- .../asio/include/asio/handler_invoke_hook.hpp | 2 +- .../include/asio/high_resolution_timer.hpp | 2 +- .../asio/impl/any_completion_executor.ipp | 130 + .../include/asio/impl/any_io_executor.ipp | 141 ++ .../asio/{experimental => }/impl/append.hpp | 50 +- .../asio/{experimental => }/impl/as_tuple.hpp | 124 +- .../asio/include/asio/impl/awaitable.hpp | 445 +++- .../asio/impl/buffered_read_stream.hpp | 47 +- .../asio/impl/buffered_write_stream.hpp | 47 +- .../include/asio/impl/cancellation_signal.ipp | 96 + .../asio/include/asio/impl/co_spawn.hpp | 151 +- .../asio/include/asio/impl/compose.hpp | 687 ------ .../asio/include/asio/impl/connect.hpp | 135 +- .../asio/include/asio/impl/connect_pipe.hpp | 73 + .../asio/include/asio/impl/connect_pipe.ipp | 149 ++ .../asio/include/asio/impl/consign.hpp | 202 ++ .../asio/include/asio/impl/deferred.hpp | 156 ++ .../asio/include/asio/impl/detached.hpp | 2 +- .../asio/include/asio/impl/error.ipp | 2 +- .../asio/include/asio/impl/error_code.ipp | 2 +- .../include/asio/impl/execution_context.hpp | 2 +- .../include/asio/impl/execution_context.ipp | 2 +- .../asio/include/asio/impl/executor.hpp | 2 +- .../asio/include/asio/impl/executor.ipp | 2 +- .../include/asio/impl/handler_alloc_hook.ipp | 4 +- .../asio/include/asio/impl/io_context.hpp | 100 +- .../asio/include/asio/impl/io_context.ipp | 3 +- .../include/asio/impl/multiple_exceptions.ipp | 2 +- .../asio/{experimental => }/impl/prepend.hpp | 46 +- .../asio/include/asio/impl/read.hpp | 197 +- .../asio/include/asio/impl/read_at.hpp | 115 +- .../asio/include/asio/impl/read_until.hpp | 306 ++- .../asio/include/asio/impl/redirect_error.hpp | 93 +- .../include/asio/impl/serial_port_base.hpp | 2 +- .../include/asio/impl/serial_port_base.ipp | 2 +- .../asio/include/asio/impl/spawn.hpp | 1653 ++++++++++--- .../asio/include/asio/impl/src.hpp | 14 +- .../asio/include/asio/impl/system_context.hpp | 2 +- .../asio/include/asio/impl/system_context.ipp | 2 +- .../include/asio/impl/system_executor.hpp | 2 +- .../asio/include/asio/impl/thread_pool.hpp | 2 +- .../asio/include/asio/impl/thread_pool.ipp | 9 +- .../asio/include/asio/impl/use_awaitable.hpp | 26 +- .../asio/include/asio/impl/use_future.hpp | 31 +- .../asio/include/asio/impl/write.hpp | 213 +- .../asio/include/asio/impl/write_at.hpp | 117 +- .../asio/include/asio/io_context.hpp | 238 +- .../asio/include/asio/io_context_strand.hpp | 18 +- .../asio/include/asio/io_service.hpp | 2 +- .../asio/include/asio/io_service_strand.hpp | 2 +- .../asio/include/asio/ip/address.hpp | 2 +- .../asio/include/asio/ip/address_v4.hpp | 81 +- .../include/asio/ip/address_v4_iterator.hpp | 2 +- .../asio/include/asio/ip/address_v4_range.hpp | 2 +- .../asio/include/asio/ip/address_v6.hpp | 36 +- .../include/asio/ip/address_v6_iterator.hpp | 2 +- .../asio/include/asio/ip/address_v6_range.hpp | 2 +- .../asio/include/asio/ip/bad_address_cast.hpp | 2 +- .../asio/include/asio/ip/basic_endpoint.hpp | 2 +- .../asio/include/asio/ip/basic_resolver.hpp | 194 +- .../include/asio/ip/basic_resolver_entry.hpp | 2 +- .../asio/ip/basic_resolver_iterator.hpp | 2 +- .../include/asio/ip/basic_resolver_query.hpp | 2 +- .../asio/ip/basic_resolver_results.hpp | 2 +- .../asio/include/asio/ip/detail/endpoint.hpp | 2 +- .../include/asio/ip/detail/impl/endpoint.ipp | 2 +- .../include/asio/ip/detail/socket_option.hpp | 2 +- .../asio/include/asio/ip/host_name.hpp | 2 +- .../asio/include/asio/ip/icmp.hpp | 2 +- .../asio/include/asio/ip/impl/address.hpp | 2 +- .../asio/include/asio/ip/impl/address.ipp | 2 +- .../asio/include/asio/ip/impl/address_v4.hpp | 2 +- .../asio/include/asio/ip/impl/address_v4.ipp | 2 +- .../asio/include/asio/ip/impl/address_v6.hpp | 2 +- .../asio/include/asio/ip/impl/address_v6.ipp | 2 +- .../include/asio/ip/impl/basic_endpoint.hpp | 2 +- .../asio/include/asio/ip/impl/host_name.ipp | 2 +- .../asio/include/asio/ip/impl/network_v4.hpp | 2 +- .../asio/include/asio/ip/impl/network_v4.ipp | 6 +- .../asio/include/asio/ip/impl/network_v6.hpp | 2 +- .../asio/include/asio/ip/impl/network_v6.ipp | 6 +- .../asio/include/asio/ip/multicast.hpp | 2 +- .../asio/include/asio/ip/network_v4.hpp | 4 +- .../asio/include/asio/ip/network_v6.hpp | 2 +- .../asio/include/asio/ip/resolver_base.hpp | 2 +- .../include/asio/ip/resolver_query_base.hpp | 2 +- .../asio/include/asio/ip/tcp.hpp | 2 +- .../asio/include/asio/ip/udp.hpp | 2 +- .../asio/include/asio/ip/unicast.hpp | 2 +- .../asio/include/asio/ip/v6_only.hpp | 4 +- .../include/asio/is_applicable_property.hpp | 2 +- .../include/asio/is_contiguous_iterator.hpp | 45 + .../asio/include/asio/is_executor.hpp | 2 +- .../asio/include/asio/is_read_buffered.hpp | 2 +- .../asio/include/asio/is_write_buffered.hpp | 2 +- .../include/asio/local/basic_endpoint.hpp | 2 +- .../asio/include/asio/local/connect_pair.hpp | 2 +- .../include/asio/local/datagram_protocol.hpp | 2 +- .../include/asio/local/detail/endpoint.hpp | 2 +- .../asio/local/detail/impl/endpoint.ipp | 2 +- .../asio/local/seq_packet_protocol.hpp | 84 + .../include/asio/local/stream_protocol.hpp | 2 +- .../asio/include/asio/multiple_exceptions.hpp | 2 +- .../asio/include/asio/packaged_task.hpp | 2 +- .../asio/include/asio/placeholders.hpp | 2 +- .../include/asio/posix/basic_descriptor.hpp | 109 +- .../asio/posix/basic_stream_descriptor.hpp | 126 +- .../asio/include/asio/posix/descriptor.hpp | 2 +- .../include/asio/posix/descriptor_base.hpp | 2 +- .../include/asio/posix/stream_descriptor.hpp | 2 +- external_libraries/asio/include/asio/post.hpp | 182 +- .../asio/include/asio/prefer.hpp | 2 +- .../asio/include/asio/prepend.hpp | 78 + .../asio/include/asio/query.hpp | 2 +- .../asio/include/asio/random_access_file.hpp | 35 + external_libraries/asio/include/asio/read.hpp | 398 ++-- .../asio/include/asio/read_at.hpp | 163 +- .../asio/include/asio/read_until.hpp | 467 ++-- .../asio/include/asio/readable_pipe.hpp | 35 + .../asio/include/asio/recycling_allocator.hpp | 138 ++ .../asio/include/asio/redirect_error.hpp | 6 +- .../asio/include/asio/registered_buffer.hpp | 356 +++ .../asio/include/asio/require.hpp | 2 +- .../asio/include/asio/require_concept.hpp | 2 +- .../asio/include/asio/serial_port.hpp | 2 +- .../asio/include/asio/serial_port_base.hpp | 2 +- .../asio/include/asio/signal_set.hpp | 2 +- .../asio/include/asio/signal_set_base.hpp | 182 ++ .../asio/include/asio/socket_base.hpp | 2 +- .../asio/include/asio/spawn.hpp | 736 +++++- external_libraries/asio/include/asio/ssl.hpp | 2 +- .../asio/include/asio/ssl/context.hpp | 5 +- .../asio/include/asio/ssl/context_base.hpp | 48 +- .../asio/ssl/detail/buffered_handshake_op.hpp | 2 +- .../asio/include/asio/ssl/detail/engine.hpp | 5 +- .../include/asio/ssl/detail/handshake_op.hpp | 2 +- .../include/asio/ssl/detail/impl/engine.ipp | 20 +- .../asio/ssl/detail/impl/openssl_init.ipp | 10 +- .../asio/include/asio/ssl/detail/io.hpp | 18 +- .../include/asio/ssl/detail/openssl_init.hpp | 2 +- .../include/asio/ssl/detail/openssl_types.hpp | 2 +- .../asio/ssl/detail/password_callback.hpp | 2 +- .../asio/include/asio/ssl/detail/read_op.hpp | 2 +- .../include/asio/ssl/detail/shutdown_op.hpp | 2 +- .../include/asio/ssl/detail/stream_core.hpp | 17 +- .../asio/ssl/detail/verify_callback.hpp | 2 +- .../asio/include/asio/ssl/detail/write_op.hpp | 2 +- .../asio/include/asio/ssl/error.hpp | 2 +- .../asio/ssl/host_name_verification.hpp | 2 +- .../asio/include/asio/ssl/impl/context.hpp | 2 +- .../asio/include/asio/ssl/impl/context.ipp | 204 +- .../asio/include/asio/ssl/impl/error.ipp | 28 +- .../asio/ssl/impl/host_name_verification.ipp | 2 +- .../asio/ssl/impl/rfc2818_verification.ipp | 2 +- .../asio/include/asio/ssl/impl/src.hpp | 2 +- .../include/asio/ssl/rfc2818_verification.hpp | 2 +- .../asio/include/asio/ssl/stream.hpp | 207 +- .../asio/include/asio/ssl/stream_base.hpp | 2 +- .../asio/include/asio/ssl/verify_context.hpp | 2 +- .../asio/include/asio/ssl/verify_mode.hpp | 2 +- .../asio/include/asio/static_thread_pool.hpp | 2 +- .../asio/include/asio/steady_timer.hpp | 2 +- .../asio/include/asio/strand.hpp | 31 +- .../asio/include/asio/stream_file.hpp | 35 + .../asio/include/asio/streambuf.hpp | 2 +- .../asio/include/asio/system_context.hpp | 2 +- .../asio/include/asio/system_error.hpp | 2 +- .../asio/include/asio/system_executor.hpp | 15 +- .../asio/include/asio/system_timer.hpp | 2 +- .../asio/include/asio/this_coro.hpp | 24 +- .../asio/include/asio/thread.hpp | 2 +- .../asio/include/asio/thread_pool.hpp | 52 +- .../asio/include/asio/time_traits.hpp | 2 +- .../include/asio/traits/bulk_execute_free.hpp | 2 +- .../asio/traits/bulk_execute_member.hpp | 2 +- .../asio/include/asio/traits/connect_free.hpp | 2 +- .../include/asio/traits/connect_member.hpp | 2 +- .../asio/traits/equality_comparable.hpp | 2 +- .../asio/include/asio/traits/execute_free.hpp | 2 +- .../include/asio/traits/execute_member.hpp | 2 +- .../asio/include/asio/traits/prefer_free.hpp | 2 +- .../include/asio/traits/prefer_member.hpp | 2 +- .../asio/include/asio/traits/query_free.hpp | 2 +- .../asio/include/asio/traits/query_member.hpp | 2 +- .../traits/query_static_constexpr_member.hpp | 2 +- .../asio/traits/require_concept_free.hpp | 2 +- .../asio/traits/require_concept_member.hpp | 2 +- .../asio/include/asio/traits/require_free.hpp | 2 +- .../include/asio/traits/require_member.hpp | 2 +- .../include/asio/traits/schedule_free.hpp | 2 +- .../include/asio/traits/schedule_member.hpp | 2 +- .../include/asio/traits/set_done_free.hpp | 2 +- .../include/asio/traits/set_done_member.hpp | 2 +- .../include/asio/traits/set_error_free.hpp | 2 +- .../include/asio/traits/set_error_member.hpp | 2 +- .../include/asio/traits/set_value_free.hpp | 2 +- .../include/asio/traits/set_value_member.hpp | 2 +- .../asio/include/asio/traits/start_free.hpp | 2 +- .../asio/include/asio/traits/start_member.hpp | 2 +- .../asio/include/asio/traits/static_query.hpp | 2 +- .../include/asio/traits/static_require.hpp | 2 +- .../asio/traits/static_require_concept.hpp | 2 +- .../asio/include/asio/traits/submit_free.hpp | 2 +- .../include/asio/traits/submit_member.hpp | 2 +- .../asio/include/asio/ts/buffer.hpp | 2 +- .../asio/include/asio/ts/executor.hpp | 2 +- .../asio/include/asio/ts/internet.hpp | 2 +- .../asio/include/asio/ts/io_context.hpp | 2 +- .../asio/include/asio/ts/net.hpp | 2 +- .../asio/include/asio/ts/netfwd.hpp | 2 +- .../asio/include/asio/ts/socket.hpp | 2 +- .../asio/include/asio/ts/timer.hpp | 2 +- .../asio/include/asio/unyield.hpp | 2 +- .../asio/include/asio/use_awaitable.hpp | 7 +- .../asio/include/asio/use_future.hpp | 17 +- .../asio/include/asio/uses_executor.hpp | 2 +- .../asio/include/asio/version.hpp | 4 +- .../asio/include/asio/wait_traits.hpp | 2 +- .../asio/windows/basic_object_handle.hpp | 86 +- .../asio/windows/basic_overlapped_handle.hpp | 103 +- .../windows/basic_random_access_handle.hpp | 131 +- .../asio/windows/basic_stream_handle.hpp | 127 +- .../include/asio/windows/object_handle.hpp | 2 +- .../asio/windows/overlapped_handle.hpp | 2 +- .../include/asio/windows/overlapped_ptr.hpp | 2 +- .../asio/windows/random_access_handle.hpp | 2 +- .../include/asio/windows/stream_handle.hpp | 2 +- .../asio/include/asio/writable_pipe.hpp | 35 + .../asio/include/asio/write.hpp | 392 ++-- .../asio/include/asio/write_at.hpp | 165 +- .../asio/include/asio/yield.hpp | 2 +- external_libraries/pybind11/.appveyor.yml | 6 +- external_libraries/pybind11/.clang-format | 19 + external_libraries/pybind11/.clang-tidy | 102 +- .../pybind11/.codespell-ignore-lines | 24 + external_libraries/pybind11/.gitattributes | 1 + .../pybind11/.github/CONTRIBUTING.md | 32 +- .../.github/ISSUE_TEMPLATE/bug-report.md | 28 - .../.github/ISSUE_TEMPLATE/bug-report.yml | 61 + .../.github/ISSUE_TEMPLATE/config.yml | 3 + .../.github/ISSUE_TEMPLATE/feature-request.md | 16 - .../.github/ISSUE_TEMPLATE/question.md | 21 - .../pybind11/.github/dependabot.yml | 9 - .../pybind11/.github/matchers/pylint.json | 32 + .../pybind11/.github/pull_request_template.md | 4 + .../pybind11/.github/workflows/ci.yml | 662 ++++-- .../pybind11/.github/workflows/configure.yml | 38 +- .../pybind11/.github/workflows/format.yml | 26 +- .../pybind11/.github/workflows/labeler.yml | 11 +- .../pybind11/.github/workflows/pip.yml | 47 +- .../pybind11/.github/workflows/upstream.yml | 116 + external_libraries/pybind11/.gitignore | 1 + .../pybind11/.pre-commit-config.yaml | 148 +- external_libraries/pybind11/CMakeLists.txt | 60 +- external_libraries/pybind11/MANIFEST.in | 4 +- external_libraries/pybind11/README.rst | 28 +- external_libraries/pybind11/SECURITY.md | 13 + external_libraries/pybind11/docs/Doxyfile | 4 +- .../pybind11/docs/_static/css/custom.css | 3 + .../pybind11/docs/_static/theme_overrides.css | 11 - .../pybind11/docs/advanced/cast/custom.rst | 8 +- .../pybind11/docs/advanced/cast/eigen.rst | 6 +- .../pybind11/docs/advanced/cast/overview.rst | 183 +- .../pybind11/docs/advanced/cast/stl.rst | 8 +- .../pybind11/docs/advanced/cast/strings.rst | 61 +- .../pybind11/docs/advanced/classes.rst | 140 +- .../pybind11/docs/advanced/embedding.rst | 29 +- .../pybind11/docs/advanced/exceptions.rst | 121 +- .../pybind11/docs/advanced/functions.rst | 69 +- .../pybind11/docs/advanced/misc.rst | 79 +- .../pybind11/docs/advanced/pycpp/numpy.rst | 61 +- .../pybind11/docs/advanced/pycpp/object.rst | 37 +- .../docs/advanced/pycpp/utilities.rst | 12 +- .../pybind11/docs/advanced/smart_ptrs.rst | 3 +- external_libraries/pybind11/docs/basics.rst | 11 +- external_libraries/pybind11/docs/benchmark.py | 33 +- .../pybind11/docs/changelog.rst | 1003 +++++++- external_libraries/pybind11/docs/classes.rst | 73 +- .../pybind11/docs/compiling.rst | 54 +- external_libraries/pybind11/docs/conf.py | 36 +- external_libraries/pybind11/docs/faq.rst | 47 +- .../pybind11/docs/pybind11-logo.png | Bin 58510 -> 61034 bytes .../pybind11/docs/reference.rst | 3 + external_libraries/pybind11/docs/release.rst | 79 +- .../pybind11/docs/requirements.txt | 14 +- external_libraries/pybind11/docs/upgrade.rst | 33 +- .../pybind11/include/pybind11/attr.h | 368 ++- .../pybind11/include/pybind11/buffer_info.h | 140 +- .../pybind11/include/pybind11/cast.h | 1184 ++++++---- .../pybind11/include/pybind11/chrono.h | 173 +- .../pybind11/include/pybind11/complex.h | 31 +- .../pybind11/include/pybind11/detail/class.h | 335 +-- .../pybind11/include/pybind11/detail/common.h | 1090 ++++++--- .../pybind11/include/pybind11/detail/descr.h | 117 +- .../pybind11/include/pybind11/detail/init.h | 288 ++- .../include/pybind11/detail/internals.h | 555 +++-- .../pybind11/detail/type_caster_base.h | 853 ++++--- .../pybind11/include/pybind11/detail/typeid.h | 30 +- .../pybind11/include/pybind11/eigen.h | 594 +---- .../pybind11/include/pybind11/eigen/common.h | 9 + .../pybind11/include/pybind11/eigen/matrix.h | 714 ++++++ .../pybind11/include/pybind11/eigen/tensor.h | 516 ++++ .../pybind11/include/pybind11/embed.h | 233 +- .../pybind11/include/pybind11/eval.h | 104 +- .../pybind11/include/pybind11/functional.h | 82 +- .../pybind11/include/pybind11/gil.h | 122 +- .../pybind11/include/pybind11/iostream.h | 82 +- .../pybind11/include/pybind11/numpy.h | 1401 ++++++----- .../pybind11/include/pybind11/operators.h | 247 +- .../pybind11/include/pybind11/options.h | 57 +- .../pybind11/include/pybind11/pybind11.h | 2083 +++++++++++------ .../pybind11/include/pybind11/pytypes.h | 1841 +++++++++++---- .../pybind11/include/pybind11/stl.h | 289 ++- .../include/pybind11/stl/filesystem.h | 79 +- .../pybind11/include/pybind11/stl_bind.h | 644 +++-- .../pybind11/type_caster_pyobject_ptr.h | 61 + external_libraries/pybind11/noxfile.py | 44 +- .../pybind11/pybind11/__init__.py | 11 +- .../pybind11/pybind11/__main__.py | 26 +- .../pybind11/pybind11/_version.py | 6 +- .../pybind11/pybind11/_version.pyi | 6 - .../pybind11/pybind11/commands.py | 33 +- .../pybind11/pybind11/setup_helpers.py | 255 +- .../pybind11/pybind11/setup_helpers.pyi | 64 - external_libraries/pybind11/pyproject.toml | 99 +- external_libraries/pybind11/setup.cfg | 36 +- external_libraries/pybind11/setup.py | 138 +- .../pybind11/tests/CMakeLists.txt | 277 ++- external_libraries/pybind11/tests/conftest.py | 105 +- .../pybind11/tests/constructor_stats.h | 143 +- .../pybind11/tests/cross_module_gil_utils.cpp | 111 +- ...s_module_interleaved_error_already_set.cpp | 51 + .../tests/eigen_tensor_avoid_stl_array.cpp | 14 + external_libraries/pybind11/tests/env.py | 8 +- .../tests/extra_python_package/test_files.py | 160 +- .../extra_setuptools/test_setuphelper.py | 30 +- .../pybind11/tests/local_bindings.h | 52 +- external_libraries/pybind11/tests/object.h | 108 +- .../tests/pybind11_cross_module_tests.cpp | 86 +- .../pybind11/tests/pybind11_tests.cpp | 60 +- .../pybind11/tests/pybind11_tests.h | 48 +- external_libraries/pybind11/tests/pytest.ini | 9 +- .../pybind11/tests/requirements.txt | 19 +- .../pybind11/tests/test_async.cpp | 5 +- .../pybind11/tests/test_async.py | 5 +- .../pybind11/tests/test_buffers.cpp | 127 +- .../pybind11/tests/test_buffers.py | 83 +- .../pybind11/tests/test_builtin_casters.cpp | 330 ++- .../pybind11/tests/test_builtin_casters.py | 231 +- .../pybind11/tests/test_call_policies.cpp | 46 +- .../pybind11/tests/test_call_policies.py | 4 +- .../pybind11/tests/test_callbacks.cpp | 160 +- .../pybind11/tests/test_callbacks.py | 64 +- .../pybind11/tests/test_chrono.cpp | 33 +- .../pybind11/tests/test_chrono.py | 10 +- .../pybind11/tests/test_class.cpp | 399 ++-- .../pybind11/tests/test_class.py | 43 +- .../tests/test_cmake_build/CMakeLists.txt | 3 - .../pybind11/tests/test_cmake_build/embed.cpp | 8 +- .../installed_embed/CMakeLists.txt | 14 +- .../installed_function/CMakeLists.txt | 11 +- .../installed_target/CMakeLists.txt | 11 +- .../subdirectory_embed/CMakeLists.txt | 14 +- .../subdirectory_function/CMakeLists.txt | 11 +- .../subdirectory_target/CMakeLists.txt | 11 +- .../pybind11/tests/test_cmake_build/test.py | 6 +- .../pybind11/tests/test_const_name.cpp | 55 + .../pybind11/tests/test_const_name.py | 29 + .../tests/test_constants_and_functions.cpp | 94 +- .../tests/test_constants_and_functions.py | 5 +- .../pybind11/tests/test_copy_move.cpp | 443 +++- .../pybind11/tests/test_copy_move.py | 9 +- .../tests/test_custom_type_casters.cpp | 146 +- .../tests/test_custom_type_casters.py | 18 +- .../pybind11/tests/test_custom_type_setup.cpp | 41 + .../pybind11/tests/test_custom_type_setup.py | 48 + .../pybind11/tests/test_docstring_options.cpp | 108 +- .../pybind11/tests/test_docstring_options.py | 24 +- .../{test_eigen.cpp => test_eigen_matrix.cpp} | 247 +- .../{test_eigen.py => test_eigen_matrix.py} | 201 +- .../pybind11/tests/test_eigen_tensor.cpp | 18 + .../pybind11/tests/test_eigen_tensor.inl | 333 +++ .../pybind11/tests/test_eigen_tensor.py | 288 +++ .../pybind11/tests/test_embed/CMakeLists.txt | 5 +- .../pybind11/tests/test_embed/catch.cpp | 29 +- .../tests/test_embed/external_module.cpp | 11 +- .../tests/test_embed/test_interpreter.cpp | 291 ++- .../tests/test_embed/test_interpreter.py | 8 +- .../tests/test_embed/test_trampoline.py | 16 + .../pybind11/tests/test_enum.cpp | 106 +- .../pybind11/tests/test_enum.py | 38 +- .../pybind11/tests/test_eval.cpp | 47 +- .../pybind11/tests/test_eval.py | 21 +- .../pybind11/tests/test_eval_call.py | 1 - .../pybind11/tests/test_exceptions.cpp | 211 +- .../pybind11/tests/test_exceptions.h | 3 +- .../pybind11/tests/test_exceptions.py | 232 +- .../tests/test_factory_constructors.cpp | 158 +- .../tests/test_factory_constructors.py | 16 +- .../pybind11/tests/test_gil_scoped.cpp | 141 +- .../pybind11/tests/test_gil_scoped.py | 226 +- .../pybind11/tests/test_iostream.cpp | 33 +- .../pybind11/tests/test_iostream.py | 120 +- .../tests/test_kwargs_and_defaults.cpp | 242 +- .../tests/test_kwargs_and_defaults.py | 144 +- .../pybind11/tests/test_local_bindings.cpp | 43 +- .../pybind11/tests/test_local_bindings.py | 7 +- .../tests/test_methods_and_attributes.cpp | 250 +- .../tests/test_methods_and_attributes.py | 101 +- .../pybind11/tests/test_modules.cpp | 69 +- .../pybind11/tests/test_modules.py | 48 +- .../tests/test_multiple_inheritance.cpp | 235 +- .../tests/test_multiple_inheritance.py | 148 +- .../pybind11/tests/test_numpy_array.cpp | 346 ++- .../pybind11/tests/test_numpy_array.py | 156 +- .../pybind11/tests/test_numpy_dtypes.cpp | 386 +-- .../pybind11/tests/test_numpy_dtypes.py | 80 +- .../pybind11/tests/test_numpy_vectorize.cpp | 38 +- .../pybind11/tests/test_numpy_vectorize.py | 4 +- .../pybind11/tests/test_opaque_types.cpp | 18 +- .../pybind11/tests/test_opaque_types.py | 8 +- .../tests/test_operator_overloading.cpp | 184 +- .../tests/test_operator_overloading.py | 16 +- .../pybind11/tests/test_pickling.cpp | 45 +- .../pybind11/tests/test_pickling.py | 24 +- .../pybind11/tests/test_pytypes.cpp | 590 ++++- .../pybind11/tests/test_pytypes.py | 541 ++++- .../tests/test_sequences_and_iterators.cpp | 307 ++- .../tests/test_sequences_and_iterators.py | 85 +- .../pybind11/tests/test_smart_ptr.cpp | 139 +- .../pybind11/tests/test_smart_ptr.py | 13 +- .../pybind11/tests/test_stl.cpp | 376 ++- external_libraries/pybind11/tests/test_stl.py | 109 +- .../pybind11/tests/test_stl_binders.cpp | 139 +- .../pybind11/tests/test_stl_binders.py | 104 +- .../tests/test_tagbased_polymorphic.cpp | 117 +- .../tests/test_tagbased_polymorphic.py | 1 - .../pybind11/tests/test_thread.cpp | 66 + .../pybind11/tests/test_thread.py | 42 + .../tests/test_type_caster_pyobject_ptr.cpp | 130 + .../tests/test_type_caster_pyobject_ptr.py | 104 + .../pybind11/tests/test_union.py | 1 - .../tests/test_unnamed_namespace_a.cpp | 38 + .../tests/test_unnamed_namespace_a.py | 34 + .../tests/test_unnamed_namespace_b.cpp | 13 + .../tests/test_unnamed_namespace_b.py | 5 + .../tests/test_vector_unique_ptr_member.cpp | 54 + .../tests/test_vector_unique_ptr_member.py | 14 + .../pybind11/tests/test_virtual_functions.cpp | 341 ++- .../pybind11/tests/test_virtual_functions.py | 78 +- .../pybind11/tools/FindCatch.cmake | 10 +- .../pybind11/tools/FindPythonLibsNew.cmake | 66 +- .../pybind11/tools/JoinPaths.cmake | 23 + .../codespell_ignore_lines_from_errors.py | 39 + external_libraries/pybind11/tools/libsize.py | 6 +- .../pybind11/tools/make_changelog.py | 12 +- .../pybind11/tools/pybind11.pc.in | 7 + .../pybind11/tools/pybind11Common.cmake | 84 +- .../pybind11/tools/pybind11Config.cmake.in | 19 +- .../pybind11/tools/pybind11NewTools.cmake | 57 +- .../pybind11/tools/pybind11Tools.cmake | 93 +- .../pybind11/tools/setup_global.py.in | 14 +- .../pybind11/tools/setup_main.py.in | 9 +- tests/CMakeLists.txt | 3 +- tests/co_sim_io/c/mpi/dummy_mpi_test.c | 6 +- 917 files changed, 63717 insertions(+), 17759 deletions(-) create mode 100644 external_libraries/asio/include/asio/any_completion_executor.hpp create mode 100644 external_libraries/asio/include/asio/any_completion_handler.hpp create mode 100644 external_libraries/asio/include/asio/append.hpp create mode 100644 external_libraries/asio/include/asio/as_tuple.hpp create mode 100644 external_libraries/asio/include/asio/associated_immediate_executor.hpp create mode 100644 external_libraries/asio/include/asio/basic_file.hpp create mode 100644 external_libraries/asio/include/asio/basic_random_access_file.hpp create mode 100644 external_libraries/asio/include/asio/basic_readable_pipe.hpp create mode 100644 external_libraries/asio/include/asio/basic_stream_file.hpp create mode 100644 external_libraries/asio/include/asio/basic_writable_pipe.hpp create mode 100644 external_libraries/asio/include/asio/bind_allocator.hpp create mode 100644 external_libraries/asio/include/asio/bind_immediate_executor.hpp create mode 100644 external_libraries/asio/include/asio/buffer_registration.hpp create mode 100644 external_libraries/asio/include/asio/connect_pipe.hpp create mode 100644 external_libraries/asio/include/asio/consign.hpp create mode 100644 external_libraries/asio/include/asio/deferred.hpp create mode 100644 external_libraries/asio/include/asio/detail/composed_work.hpp create mode 100644 external_libraries/asio/include/asio/detail/exception.hpp create mode 100644 external_libraries/asio/include/asio/detail/impl/io_uring_descriptor_service.ipp create mode 100644 external_libraries/asio/include/asio/detail/impl/io_uring_file_service.ipp create mode 100644 external_libraries/asio/include/asio/detail/impl/io_uring_service.hpp create mode 100644 external_libraries/asio/include/asio/detail/impl/io_uring_service.ipp create mode 100644 external_libraries/asio/include/asio/detail/impl/io_uring_socket_service_base.ipp rename external_libraries/asio/include/asio/detail/impl/{reactive_serial_port_service.ipp => posix_serial_port_service.ipp} (68%) create mode 100644 external_libraries/asio/include/asio/detail/impl/win_iocp_file_service.ipp rename external_libraries/asio/include/asio/{impl/defer.hpp => detail/initiate_defer.hpp} (82%) rename external_libraries/asio/include/asio/{impl/dispatch.hpp => detail/initiate_dispatch.hpp} (76%) rename external_libraries/asio/include/asio/{impl/post.hpp => detail/initiate_post.hpp} (82%) create mode 100644 external_libraries/asio/include/asio/detail/io_uring_descriptor_read_at_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_descriptor_read_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_descriptor_service.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_descriptor_write_at_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_descriptor_write_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_file_service.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_null_buffers_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_operation.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_service.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_accept_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_connect_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_recv_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_recvfrom_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_recvmsg_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_send_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_sendto_op.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_service.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_socket_service_base.hpp create mode 100644 external_libraries/asio/include/asio/detail/io_uring_wait_op.hpp rename external_libraries/asio/include/asio/detail/{reactive_serial_port_service.hpp => posix_serial_port_service.hpp} (81%) delete mode 100644 external_libraries/asio/include/asio/detail/reactor_fwd.hpp create mode 100644 external_libraries/asio/include/asio/detail/scheduler_task.hpp create mode 100644 external_libraries/asio/include/asio/detail/utility.hpp create mode 100644 external_libraries/asio/include/asio/detail/win_iocp_file_service.hpp create mode 100644 external_libraries/asio/include/asio/experimental/basic_channel.hpp create mode 100644 external_libraries/asio/include/asio/experimental/basic_concurrent_channel.hpp create mode 100644 external_libraries/asio/include/asio/experimental/channel.hpp create mode 100644 external_libraries/asio/include/asio/experimental/channel_error.hpp create mode 100644 external_libraries/asio/include/asio/experimental/channel_traits.hpp create mode 100644 external_libraries/asio/include/asio/experimental/co_composed.hpp create mode 100644 external_libraries/asio/include/asio/experimental/co_spawn.hpp create mode 100644 external_libraries/asio/include/asio/experimental/concurrent_channel.hpp rename external_libraries/asio/include/asio/experimental/{detail => }/coro_traits.hpp (60%) create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_handler.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_message.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_operation.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_payload.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_receive_op.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_send_functions.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_send_op.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/channel_service.hpp delete mode 100644 external_libraries/asio/include/asio/experimental/detail/completion_handler_erasure.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/coro_completion_handler.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/has_signature.hpp create mode 100644 external_libraries/asio/include/asio/experimental/detail/impl/channel_service.hpp create mode 100644 external_libraries/asio/include/asio/experimental/impl/channel_error.ipp create mode 100644 external_libraries/asio/include/asio/experimental/impl/co_composed.hpp create mode 100644 external_libraries/asio/include/asio/experimental/impl/coro.hpp delete mode 100644 external_libraries/asio/include/asio/experimental/impl/deferred.hpp create mode 100644 external_libraries/asio/include/asio/experimental/impl/use_coro.hpp create mode 100644 external_libraries/asio/include/asio/experimental/impl/use_promise.hpp create mode 100644 external_libraries/asio/include/asio/experimental/use_promise.hpp create mode 100644 external_libraries/asio/include/asio/file_base.hpp create mode 100644 external_libraries/asio/include/asio/impl/any_completion_executor.ipp create mode 100644 external_libraries/asio/include/asio/impl/any_io_executor.ipp rename external_libraries/asio/include/asio/{experimental => }/impl/append.hpp (81%) rename external_libraries/asio/include/asio/{experimental => }/impl/as_tuple.hpp (60%) create mode 100644 external_libraries/asio/include/asio/impl/cancellation_signal.ipp delete mode 100644 external_libraries/asio/include/asio/impl/compose.hpp create mode 100644 external_libraries/asio/include/asio/impl/connect_pipe.hpp create mode 100644 external_libraries/asio/include/asio/impl/connect_pipe.ipp create mode 100644 external_libraries/asio/include/asio/impl/consign.hpp create mode 100644 external_libraries/asio/include/asio/impl/deferred.hpp rename external_libraries/asio/include/asio/{experimental => }/impl/prepend.hpp (82%) create mode 100644 external_libraries/asio/include/asio/is_contiguous_iterator.hpp create mode 100644 external_libraries/asio/include/asio/local/seq_packet_protocol.hpp create mode 100644 external_libraries/asio/include/asio/prepend.hpp create mode 100644 external_libraries/asio/include/asio/random_access_file.hpp create mode 100644 external_libraries/asio/include/asio/readable_pipe.hpp create mode 100644 external_libraries/asio/include/asio/recycling_allocator.hpp create mode 100644 external_libraries/asio/include/asio/registered_buffer.hpp create mode 100644 external_libraries/asio/include/asio/signal_set_base.hpp create mode 100644 external_libraries/asio/include/asio/stream_file.hpp create mode 100644 external_libraries/asio/include/asio/writable_pipe.hpp create mode 100644 external_libraries/pybind11/.codespell-ignore-lines create mode 100644 external_libraries/pybind11/.gitattributes delete mode 100644 external_libraries/pybind11/.github/ISSUE_TEMPLATE/bug-report.md create mode 100644 external_libraries/pybind11/.github/ISSUE_TEMPLATE/bug-report.yml delete mode 100644 external_libraries/pybind11/.github/ISSUE_TEMPLATE/feature-request.md delete mode 100644 external_libraries/pybind11/.github/ISSUE_TEMPLATE/question.md create mode 100644 external_libraries/pybind11/.github/matchers/pylint.json create mode 100644 external_libraries/pybind11/.github/workflows/upstream.yml create mode 100644 external_libraries/pybind11/SECURITY.md create mode 100644 external_libraries/pybind11/docs/_static/css/custom.css delete mode 100644 external_libraries/pybind11/docs/_static/theme_overrides.css create mode 100644 external_libraries/pybind11/include/pybind11/eigen/common.h create mode 100644 external_libraries/pybind11/include/pybind11/eigen/matrix.h create mode 100644 external_libraries/pybind11/include/pybind11/eigen/tensor.h create mode 100644 external_libraries/pybind11/include/pybind11/type_caster_pyobject_ptr.h delete mode 100644 external_libraries/pybind11/pybind11/_version.pyi delete mode 100644 external_libraries/pybind11/pybind11/setup_helpers.pyi create mode 100644 external_libraries/pybind11/tests/cross_module_interleaved_error_already_set.cpp create mode 100644 external_libraries/pybind11/tests/eigen_tensor_avoid_stl_array.cpp create mode 100644 external_libraries/pybind11/tests/test_const_name.cpp create mode 100644 external_libraries/pybind11/tests/test_const_name.py create mode 100644 external_libraries/pybind11/tests/test_custom_type_setup.cpp create mode 100644 external_libraries/pybind11/tests/test_custom_type_setup.py rename external_libraries/pybind11/tests/{test_eigen.cpp => test_eigen_matrix.cpp} (64%) rename external_libraries/pybind11/tests/{test_eigen.py => test_eigen_matrix.py} (83%) create mode 100644 external_libraries/pybind11/tests/test_eigen_tensor.cpp create mode 100644 external_libraries/pybind11/tests/test_eigen_tensor.inl create mode 100644 external_libraries/pybind11/tests/test_eigen_tensor.py create mode 100644 external_libraries/pybind11/tests/test_embed/test_trampoline.py create mode 100644 external_libraries/pybind11/tests/test_thread.cpp create mode 100644 external_libraries/pybind11/tests/test_thread.py create mode 100644 external_libraries/pybind11/tests/test_type_caster_pyobject_ptr.cpp create mode 100644 external_libraries/pybind11/tests/test_type_caster_pyobject_ptr.py create mode 100644 external_libraries/pybind11/tests/test_unnamed_namespace_a.cpp create mode 100644 external_libraries/pybind11/tests/test_unnamed_namespace_a.py create mode 100644 external_libraries/pybind11/tests/test_unnamed_namespace_b.cpp create mode 100644 external_libraries/pybind11/tests/test_unnamed_namespace_b.py create mode 100644 external_libraries/pybind11/tests/test_vector_unique_ptr_member.cpp create mode 100644 external_libraries/pybind11/tests/test_vector_unique_ptr_member.py create mode 100644 external_libraries/pybind11/tools/JoinPaths.cmake create mode 100644 external_libraries/pybind11/tools/codespell_ignore_lines_from_errors.py create mode 100644 external_libraries/pybind11/tools/pybind11.pc.in diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6addbb1e..fa94352f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -120,7 +120,7 @@ jobs: strategy: fail-fast: false matrix: - python-version: ["3.7", "3.8", "3.9", "3.10"] + python-version: ["3.8", "3.9", "3.10", "3.11"] compiler: [GCC, ICC] timeout-minutes: 15 @@ -214,7 +214,7 @@ jobs: strategy: fail-fast: false matrix: - python-version: ["3.7", "3.8", "3.9", "3.10"] + python-version: ["3.8", "3.9", "3.10", "3.11"] timeout-minutes: 15 steps: @@ -245,7 +245,7 @@ jobs: Windows-Cpp-C: - runs-on: windows-2022 + runs-on: windows-latest name: Windows C++ & C timeout-minutes: 15 @@ -285,12 +285,12 @@ jobs: Windows-Python: - runs-on: windows-2022 + runs-on: windows-latest name: Windows Python ${{ matrix.python-version }} strategy: fail-fast: false matrix: - python-version: ["3.7", "3.8", "3.9", "3.10"] + python-version: ["3.8", "3.9", "3.10", "3.11"] timeout-minutes: 15 steps: @@ -345,7 +345,7 @@ jobs: name: CentOS 7 container: - image: kratosmultiphysics/kratos-image-ci-centos7-python35:latest + image: kratosmultiphysics/kratos-image-ci-centos7:latest steps: - uses: actions/checkout@v2 @@ -371,7 +371,7 @@ jobs: export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${GITHUB_WORKSPACE}/bin cd tests # TODO delete build dir to make sure the linking etc works correctly? (Needs to be done after running CTests) - python3.5 run_python_tests.py + python3.8 run_python_tests.py Ubuntu-old-CMake: diff --git a/CHANGELOG.md b/CHANGELOG.md index a9b76c33..e7f31b8b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -74,3 +74,8 @@ All important and notable changes in the _CoSimIO_ are documented in this file. - Brings back the Fortran interface! - Fixes compilation problems in some systems with the tests and with the pipe communication (happened only with old Linux kernels) - Minor improvements in documentation + +## 4.3.0 +- Drops support for Python < 3.6 +- Fixes problems with displaying error messages in some Windows systems +- Updates external libraries pybind (used in Python-bindings) and ASIO (socket-based communication) diff --git a/co_sim_io/sources/version.cpp b/co_sim_io/sources/version.cpp index 5db07746..c1f008bf 100644 --- a/co_sim_io/sources/version.cpp +++ b/co_sim_io/sources/version.cpp @@ -20,7 +20,7 @@ int GetMajorVersion() { } int GetMinorVersion() { - return 2; + return 3; } std::string GetPatchVersion() { diff --git a/external_libraries/asio/COPYING b/external_libraries/asio/COPYING index 532cec6c..4540e01f 100644 --- a/external_libraries/asio/COPYING +++ b/external_libraries/asio/COPYING @@ -1,4 +1,4 @@ -Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) diff --git a/external_libraries/asio/README b/external_libraries/asio/README index a5aa5cb4..6ef60c29 100644 --- a/external_libraries/asio/README +++ b/external_libraries/asio/README @@ -1,4 +1,4 @@ -asio version 1.20.0 -Released Saturday, 16 October 2021. +asio version 1.28.0 +Released Wednesday, 26 April 2023. See doc/index.html for API documentation and a tutorial. diff --git a/external_libraries/asio/include/Makefile.am b/external_libraries/asio/include/Makefile.am index 74933ee7..d7a9b9c6 100644 --- a/external_libraries/asio/include/Makefile.am +++ b/external_libraries/asio/include/Makefile.am @@ -1,16 +1,24 @@ # find . -name "*.*pp" | sed -e 's/^\.\///' | sed -e 's/^.*$/ & \\/' | sort nobase_include_HEADERS = \ + asio/any_completion_executor.hpp \ + asio/any_completion_handler.hpp \ asio/any_io_executor.hpp \ + asio/append.hpp \ + asio/as_tuple.hpp \ asio/associated_allocator.hpp \ asio/associated_cancellation_slot.hpp \ asio/associated_executor.hpp \ + asio/associated_immediate_executor.hpp \ asio/associator.hpp \ asio/async_result.hpp \ asio/awaitable.hpp \ asio/basic_datagram_socket.hpp \ asio/basic_deadline_timer.hpp \ + asio/basic_file.hpp \ asio/basic_io_object.hpp \ + asio/basic_random_access_file.hpp \ asio/basic_raw_socket.hpp \ + asio/basic_readable_pipe.hpp \ asio/basic_seq_packet_socket.hpp \ asio/basic_serial_port.hpp \ asio/basic_signal_set.hpp \ @@ -20,10 +28,14 @@ nobase_include_HEADERS = \ asio/basic_socket_streambuf.hpp \ asio/basic_streambuf_fwd.hpp \ asio/basic_streambuf.hpp \ + asio/basic_stream_file.hpp \ asio/basic_stream_socket.hpp \ asio/basic_waitable_timer.hpp \ + asio/basic_writable_pipe.hpp \ + asio/bind_allocator.hpp \ asio/bind_cancellation_slot.hpp \ asio/bind_executor.hpp \ + asio/bind_immediate_executor.hpp \ asio/buffered_read_stream_fwd.hpp \ asio/buffered_read_stream.hpp \ asio/buffered_stream_fwd.hpp \ @@ -31,6 +43,7 @@ nobase_include_HEADERS = \ asio/buffered_write_stream_fwd.hpp \ asio/buffered_write_stream.hpp \ asio/buffer.hpp \ + asio/buffer_registration.hpp \ asio/buffers_iterator.hpp \ asio/cancellation_signal.hpp \ asio/cancellation_state.hpp \ @@ -39,9 +52,12 @@ nobase_include_HEADERS = \ asio/completion_condition.hpp \ asio/compose.hpp \ asio/connect.hpp \ + asio/connect_pipe.hpp \ + asio/consign.hpp \ asio/coroutine.hpp \ asio/deadline_timer.hpp \ asio/defer.hpp \ + asio/deferred.hpp \ asio/detached.hpp \ asio/detail/array_fwd.hpp \ asio/detail/array.hpp \ @@ -59,6 +75,7 @@ nobase_include_HEADERS = \ asio/detail/chrono.hpp \ asio/detail/chrono_time_traits.hpp \ asio/detail/completion_handler.hpp \ + asio/detail/composed_work.hpp \ asio/detail/concurrency_hint.hpp \ asio/detail/conditionally_enabled_event.hpp \ asio/detail/conditionally_enabled_mutex.hpp \ @@ -76,6 +93,7 @@ nobase_include_HEADERS = \ asio/detail/epoll_reactor.hpp \ asio/detail/eventfd_select_interrupter.hpp \ asio/detail/event.hpp \ + asio/detail/exception.hpp \ asio/detail/executor_function.hpp \ asio/detail/executor_op.hpp \ asio/detail/fd_set_adapter.hpp \ @@ -102,16 +120,21 @@ nobase_include_HEADERS = \ asio/detail/impl/epoll_reactor.ipp \ asio/detail/impl/eventfd_select_interrupter.ipp \ asio/detail/impl/handler_tracking.ipp \ + asio/detail/impl/io_uring_descriptor_service.ipp \ + asio/detail/impl/io_uring_file_service.ipp \ + asio/detail/impl/io_uring_service.hpp \ + asio/detail/impl/io_uring_service.ipp \ + asio/detail/impl/io_uring_socket_service_base.ipp \ asio/detail/impl/kqueue_reactor.hpp \ asio/detail/impl/kqueue_reactor.ipp \ asio/detail/impl/null_event.ipp \ asio/detail/impl/pipe_select_interrupter.ipp \ asio/detail/impl/posix_event.ipp \ asio/detail/impl/posix_mutex.ipp \ + asio/detail/impl/posix_serial_port_service.ipp \ asio/detail/impl/posix_thread.ipp \ asio/detail/impl/posix_tss_ptr.ipp \ asio/detail/impl/reactive_descriptor_service.ipp \ - asio/detail/impl/reactive_serial_port_service.ipp \ asio/detail/impl/reactive_socket_service_base.ipp \ asio/detail/impl/resolver_service_base.ipp \ asio/detail/impl/scheduler.ipp \ @@ -131,6 +154,7 @@ nobase_include_HEADERS = \ asio/detail/impl/timer_queue_ptime.ipp \ asio/detail/impl/timer_queue_set.ipp \ asio/detail/impl/win_event.ipp \ + asio/detail/impl/win_iocp_file_service.ipp \ asio/detail/impl/win_iocp_handle_service.ipp \ asio/detail/impl/win_iocp_io_context.hpp \ asio/detail/impl/win_iocp_io_context.ipp \ @@ -145,8 +169,30 @@ nobase_include_HEADERS = \ asio/detail/impl/win_static_mutex.ipp \ asio/detail/impl/win_thread.ipp \ asio/detail/impl/win_tss_ptr.ipp \ + asio/detail/initiate_defer.hpp \ + asio/detail/initiate_dispatch.hpp \ + asio/detail/initiate_post.hpp \ asio/detail/io_control.hpp \ asio/detail/io_object_impl.hpp \ + asio/detail/io_uring_descriptor_read_at_op.hpp \ + asio/detail/io_uring_descriptor_read_op.hpp \ + asio/detail/io_uring_descriptor_service.hpp \ + asio/detail/io_uring_descriptor_write_at_op.hpp \ + asio/detail/io_uring_descriptor_write_op.hpp \ + asio/detail/io_uring_file_service.hpp \ + asio/detail/io_uring_null_buffers_op.hpp \ + asio/detail/io_uring_operation.hpp \ + asio/detail/io_uring_service.hpp \ + asio/detail/io_uring_socket_accept_op.hpp \ + asio/detail/io_uring_socket_connect_op.hpp \ + asio/detail/io_uring_socket_recvfrom_op.hpp \ + asio/detail/io_uring_socket_recvmsg_op.hpp \ + asio/detail/io_uring_socket_recv_op.hpp \ + asio/detail/io_uring_socket_send_op.hpp \ + asio/detail/io_uring_socket_sendto_op.hpp \ + asio/detail/io_uring_socket_service_base.hpp \ + asio/detail/io_uring_socket_service.hpp \ + asio/detail/io_uring_wait_op.hpp \ asio/detail/is_buffer_sequence.hpp \ asio/detail/is_executor.hpp \ asio/detail/keyword_tss_ptr.hpp \ @@ -178,6 +224,7 @@ nobase_include_HEADERS = \ asio/detail/posix_fd_set_adapter.hpp \ asio/detail/posix_global.hpp \ asio/detail/posix_mutex.hpp \ + asio/detail/posix_serial_port_service.hpp \ asio/detail/posix_signal_blocker.hpp \ asio/detail/posix_static_mutex.hpp \ asio/detail/posix_thread.hpp \ @@ -185,7 +232,6 @@ nobase_include_HEADERS = \ asio/detail/push_options.hpp \ asio/detail/reactive_descriptor_service.hpp \ asio/detail/reactive_null_buffers_op.hpp \ - asio/detail/reactive_serial_port_service.hpp \ asio/detail/reactive_socket_accept_op.hpp \ asio/detail/reactive_socket_connect_op.hpp \ asio/detail/reactive_socket_recvfrom_op.hpp \ @@ -196,7 +242,6 @@ nobase_include_HEADERS = \ asio/detail/reactive_socket_service_base.hpp \ asio/detail/reactive_socket_service.hpp \ asio/detail/reactive_wait_op.hpp \ - asio/detail/reactor_fwd.hpp \ asio/detail/reactor.hpp \ asio/detail/reactor_op.hpp \ asio/detail/reactor_op_queue.hpp \ @@ -209,6 +254,7 @@ nobase_include_HEADERS = \ asio/detail/resolver_service.hpp \ asio/detail/scheduler.hpp \ asio/detail/scheduler_operation.hpp \ + asio/detail/scheduler_task.hpp \ asio/detail/scheduler_thread_info.hpp \ asio/detail/scoped_lock.hpp \ asio/detail/scoped_ptr.hpp \ @@ -251,6 +297,7 @@ nobase_include_HEADERS = \ asio/detail/timer_scheduler.hpp \ asio/detail/tss_ptr.hpp \ asio/detail/type_traits.hpp \ + asio/detail/utility.hpp \ asio/detail/variadic_templates.hpp \ asio/detail/wait_handler.hpp \ asio/detail/wait_op.hpp \ @@ -260,6 +307,7 @@ nobase_include_HEADERS = \ asio/detail/win_fd_set_adapter.hpp \ asio/detail/win_fenced_block.hpp \ asio/detail/win_global.hpp \ + asio/detail/win_iocp_file_service.hpp \ asio/detail/win_iocp_handle_read_op.hpp \ asio/detail/win_iocp_handle_service.hpp \ asio/detail/win_iocp_handle_write_op.hpp \ @@ -346,24 +394,45 @@ nobase_include_HEADERS = \ asio/experimental/as_single.hpp \ asio/experimental/as_tuple.hpp \ asio/experimental/awaitable_operators.hpp \ + asio/experimental/basic_channel.hpp \ + asio/experimental/basic_concurrent_channel.hpp \ asio/experimental/cancellation_condition.hpp \ + asio/experimental/channel.hpp \ + asio/experimental/channel_error.hpp \ + asio/experimental/channel_traits.hpp \ + asio/experimental/co_composed.hpp \ + asio/experimental/co_spawn.hpp \ + asio/experimental/concurrent_channel.hpp \ asio/experimental/coro.hpp \ + asio/experimental/coro_traits.hpp \ asio/experimental/deferred.hpp \ - asio/experimental/detail/completion_handler_erasure.hpp \ + asio/experimental/detail/channel_handler.hpp \ + asio/experimental/detail/channel_message.hpp \ + asio/experimental/detail/channel_operation.hpp \ + asio/experimental/detail/channel_payload.hpp \ + asio/experimental/detail/channel_receive_op.hpp \ + asio/experimental/detail/channel_send_functions.hpp \ + asio/experimental/detail/channel_send_op.hpp \ + asio/experimental/detail/channel_service.hpp \ + asio/experimental/detail/coro_completion_handler.hpp \ asio/experimental/detail/coro_promise_allocator.hpp \ - asio/experimental/detail/coro_traits.hpp \ + asio/experimental/detail/has_signature.hpp \ + asio/experimental/detail/impl/channel_service.hpp \ asio/experimental/detail/partial_promise.hpp \ - asio/experimental/impl/append.hpp \ asio/experimental/impl/as_single.hpp \ - asio/experimental/impl/as_tuple.hpp \ - asio/experimental/impl/deferred.hpp \ + asio/experimental/impl/channel_error.ipp \ + asio/experimental/impl/co_composed.hpp \ + asio/experimental/impl/coro.hpp \ asio/experimental/impl/parallel_group.hpp \ - asio/experimental/impl/prepend.hpp \ asio/experimental/impl/promise.hpp \ + asio/experimental/impl/use_coro.hpp \ + asio/experimental/impl/use_promise.hpp \ asio/experimental/parallel_group.hpp \ asio/experimental/prepend.hpp \ asio/experimental/promise.hpp \ asio/experimental/use_coro.hpp \ + asio/experimental/use_promise.hpp \ + asio/file_base.hpp \ asio/generic/basic_endpoint.hpp \ asio/generic/datagram_protocol.hpp \ asio/generic/detail/endpoint.hpp \ @@ -376,15 +445,21 @@ nobase_include_HEADERS = \ asio/handler_invoke_hook.hpp \ asio/high_resolution_timer.hpp \ asio.hpp \ + asio/impl/any_completion_executor.ipp \ + asio/impl/any_io_executor.ipp \ + asio/impl/append.hpp \ + asio/impl/as_tuple.hpp \ asio/impl/awaitable.hpp \ asio/impl/buffered_read_stream.hpp \ asio/impl/buffered_write_stream.hpp \ + asio/impl/cancellation_signal.ipp \ asio/impl/co_spawn.hpp \ - asio/impl/compose.hpp \ asio/impl/connect.hpp \ - asio/impl/defer.hpp \ + asio/impl/connect_pipe.hpp \ + asio/impl/connect_pipe.ipp \ + asio/impl/consign.hpp \ + asio/impl/deferred.hpp \ asio/impl/detached.hpp \ - asio/impl/dispatch.hpp \ asio/impl/error_code.ipp \ asio/impl/error.ipp \ asio/impl/execution_context.hpp \ @@ -395,7 +470,7 @@ nobase_include_HEADERS = \ asio/impl/io_context.hpp \ asio/impl/io_context.ipp \ asio/impl/multiple_exceptions.ipp \ - asio/impl/post.hpp \ + asio/impl/prepend.hpp \ asio/impl/read_at.hpp \ asio/impl/read.hpp \ asio/impl/read_until.hpp \ @@ -458,6 +533,7 @@ nobase_include_HEADERS = \ asio/ip/unicast.hpp \ asio/ip/v6_only.hpp \ asio/is_applicable_property.hpp \ + asio/is_contiguous_iterator.hpp \ asio/is_executor.hpp \ asio/is_read_buffered.hpp \ asio/is_write_buffered.hpp \ @@ -466,6 +542,7 @@ nobase_include_HEADERS = \ asio/local/datagram_protocol.hpp \ asio/local/detail/endpoint.hpp \ asio/local/detail/impl/endpoint.ipp \ + asio/local/seq_packet_protocol.hpp \ asio/local/stream_protocol.hpp \ asio/multiple_exceptions.hpp \ asio/packaged_task.hpp \ @@ -477,15 +554,21 @@ nobase_include_HEADERS = \ asio/posix/stream_descriptor.hpp \ asio/post.hpp \ asio/prefer.hpp \ + asio/prepend.hpp \ asio/query.hpp \ + asio/random_access_file.hpp \ asio/read_at.hpp \ asio/read.hpp \ asio/read_until.hpp \ + asio/readable_pipe.hpp \ + asio/recycling_allocator.hpp \ asio/redirect_error.hpp \ + asio/registered_buffer.hpp \ asio/require.hpp \ asio/require_concept.hpp \ asio/serial_port_base.hpp \ asio/serial_port.hpp \ + asio/signal_set_base.hpp \ asio/signal_set.hpp \ asio/socket_base.hpp \ asio/spawn.hpp \ @@ -523,6 +606,7 @@ nobase_include_HEADERS = \ asio/steady_timer.hpp \ asio/strand.hpp \ asio/streambuf.hpp \ + asio/stream_file.hpp \ asio/system_context.hpp \ asio/system_error.hpp \ asio/system_executor.hpp \ @@ -585,6 +669,7 @@ nobase_include_HEADERS = \ asio/windows/overlapped_ptr.hpp \ asio/windows/random_access_handle.hpp \ asio/windows/stream_handle.hpp \ + asio/writable_pipe.hpp \ asio/write_at.hpp \ asio/write.hpp \ asio/yield.hpp diff --git a/external_libraries/asio/include/Makefile.in b/external_libraries/asio/include/Makefile.in index 4bb29452..8ae22e5b 100644 --- a/external_libraries/asio/include/Makefile.in +++ b/external_libraries/asio/include/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.16.5 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2021 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -163,8 +163,6 @@ am__define_uniq_tagged_files = \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ @@ -178,8 +176,9 @@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CXX = @CXX@ -CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ @@ -188,9 +187,8 @@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EGREP = @EGREP@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ -GREP = @GREP@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ @@ -257,9 +255,11 @@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ +pkgconfigdir = @pkgconfigdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ @@ -271,17 +271,25 @@ top_srcdir = @top_srcdir@ # find . -name "*.*pp" | sed -e 's/^\.\///' | sed -e 's/^.*$/ & \\/' | sort nobase_include_HEADERS = \ + asio/any_completion_executor.hpp \ + asio/any_completion_handler.hpp \ asio/any_io_executor.hpp \ + asio/append.hpp \ + asio/as_tuple.hpp \ asio/associated_allocator.hpp \ asio/associated_cancellation_slot.hpp \ asio/associated_executor.hpp \ + asio/associated_immediate_executor.hpp \ asio/associator.hpp \ asio/async_result.hpp \ asio/awaitable.hpp \ asio/basic_datagram_socket.hpp \ asio/basic_deadline_timer.hpp \ + asio/basic_file.hpp \ asio/basic_io_object.hpp \ + asio/basic_random_access_file.hpp \ asio/basic_raw_socket.hpp \ + asio/basic_readable_pipe.hpp \ asio/basic_seq_packet_socket.hpp \ asio/basic_serial_port.hpp \ asio/basic_signal_set.hpp \ @@ -291,10 +299,14 @@ nobase_include_HEADERS = \ asio/basic_socket_streambuf.hpp \ asio/basic_streambuf_fwd.hpp \ asio/basic_streambuf.hpp \ + asio/basic_stream_file.hpp \ asio/basic_stream_socket.hpp \ asio/basic_waitable_timer.hpp \ + asio/basic_writable_pipe.hpp \ + asio/bind_allocator.hpp \ asio/bind_cancellation_slot.hpp \ asio/bind_executor.hpp \ + asio/bind_immediate_executor.hpp \ asio/buffered_read_stream_fwd.hpp \ asio/buffered_read_stream.hpp \ asio/buffered_stream_fwd.hpp \ @@ -302,6 +314,7 @@ nobase_include_HEADERS = \ asio/buffered_write_stream_fwd.hpp \ asio/buffered_write_stream.hpp \ asio/buffer.hpp \ + asio/buffer_registration.hpp \ asio/buffers_iterator.hpp \ asio/cancellation_signal.hpp \ asio/cancellation_state.hpp \ @@ -310,9 +323,12 @@ nobase_include_HEADERS = \ asio/completion_condition.hpp \ asio/compose.hpp \ asio/connect.hpp \ + asio/connect_pipe.hpp \ + asio/consign.hpp \ asio/coroutine.hpp \ asio/deadline_timer.hpp \ asio/defer.hpp \ + asio/deferred.hpp \ asio/detached.hpp \ asio/detail/array_fwd.hpp \ asio/detail/array.hpp \ @@ -330,6 +346,7 @@ nobase_include_HEADERS = \ asio/detail/chrono.hpp \ asio/detail/chrono_time_traits.hpp \ asio/detail/completion_handler.hpp \ + asio/detail/composed_work.hpp \ asio/detail/concurrency_hint.hpp \ asio/detail/conditionally_enabled_event.hpp \ asio/detail/conditionally_enabled_mutex.hpp \ @@ -347,6 +364,7 @@ nobase_include_HEADERS = \ asio/detail/epoll_reactor.hpp \ asio/detail/eventfd_select_interrupter.hpp \ asio/detail/event.hpp \ + asio/detail/exception.hpp \ asio/detail/executor_function.hpp \ asio/detail/executor_op.hpp \ asio/detail/fd_set_adapter.hpp \ @@ -373,16 +391,21 @@ nobase_include_HEADERS = \ asio/detail/impl/epoll_reactor.ipp \ asio/detail/impl/eventfd_select_interrupter.ipp \ asio/detail/impl/handler_tracking.ipp \ + asio/detail/impl/io_uring_descriptor_service.ipp \ + asio/detail/impl/io_uring_file_service.ipp \ + asio/detail/impl/io_uring_service.hpp \ + asio/detail/impl/io_uring_service.ipp \ + asio/detail/impl/io_uring_socket_service_base.ipp \ asio/detail/impl/kqueue_reactor.hpp \ asio/detail/impl/kqueue_reactor.ipp \ asio/detail/impl/null_event.ipp \ asio/detail/impl/pipe_select_interrupter.ipp \ asio/detail/impl/posix_event.ipp \ asio/detail/impl/posix_mutex.ipp \ + asio/detail/impl/posix_serial_port_service.ipp \ asio/detail/impl/posix_thread.ipp \ asio/detail/impl/posix_tss_ptr.ipp \ asio/detail/impl/reactive_descriptor_service.ipp \ - asio/detail/impl/reactive_serial_port_service.ipp \ asio/detail/impl/reactive_socket_service_base.ipp \ asio/detail/impl/resolver_service_base.ipp \ asio/detail/impl/scheduler.ipp \ @@ -402,6 +425,7 @@ nobase_include_HEADERS = \ asio/detail/impl/timer_queue_ptime.ipp \ asio/detail/impl/timer_queue_set.ipp \ asio/detail/impl/win_event.ipp \ + asio/detail/impl/win_iocp_file_service.ipp \ asio/detail/impl/win_iocp_handle_service.ipp \ asio/detail/impl/win_iocp_io_context.hpp \ asio/detail/impl/win_iocp_io_context.ipp \ @@ -416,8 +440,30 @@ nobase_include_HEADERS = \ asio/detail/impl/win_static_mutex.ipp \ asio/detail/impl/win_thread.ipp \ asio/detail/impl/win_tss_ptr.ipp \ + asio/detail/initiate_defer.hpp \ + asio/detail/initiate_dispatch.hpp \ + asio/detail/initiate_post.hpp \ asio/detail/io_control.hpp \ asio/detail/io_object_impl.hpp \ + asio/detail/io_uring_descriptor_read_at_op.hpp \ + asio/detail/io_uring_descriptor_read_op.hpp \ + asio/detail/io_uring_descriptor_service.hpp \ + asio/detail/io_uring_descriptor_write_at_op.hpp \ + asio/detail/io_uring_descriptor_write_op.hpp \ + asio/detail/io_uring_file_service.hpp \ + asio/detail/io_uring_null_buffers_op.hpp \ + asio/detail/io_uring_operation.hpp \ + asio/detail/io_uring_service.hpp \ + asio/detail/io_uring_socket_accept_op.hpp \ + asio/detail/io_uring_socket_connect_op.hpp \ + asio/detail/io_uring_socket_recvfrom_op.hpp \ + asio/detail/io_uring_socket_recvmsg_op.hpp \ + asio/detail/io_uring_socket_recv_op.hpp \ + asio/detail/io_uring_socket_send_op.hpp \ + asio/detail/io_uring_socket_sendto_op.hpp \ + asio/detail/io_uring_socket_service_base.hpp \ + asio/detail/io_uring_socket_service.hpp \ + asio/detail/io_uring_wait_op.hpp \ asio/detail/is_buffer_sequence.hpp \ asio/detail/is_executor.hpp \ asio/detail/keyword_tss_ptr.hpp \ @@ -449,6 +495,7 @@ nobase_include_HEADERS = \ asio/detail/posix_fd_set_adapter.hpp \ asio/detail/posix_global.hpp \ asio/detail/posix_mutex.hpp \ + asio/detail/posix_serial_port_service.hpp \ asio/detail/posix_signal_blocker.hpp \ asio/detail/posix_static_mutex.hpp \ asio/detail/posix_thread.hpp \ @@ -456,7 +503,6 @@ nobase_include_HEADERS = \ asio/detail/push_options.hpp \ asio/detail/reactive_descriptor_service.hpp \ asio/detail/reactive_null_buffers_op.hpp \ - asio/detail/reactive_serial_port_service.hpp \ asio/detail/reactive_socket_accept_op.hpp \ asio/detail/reactive_socket_connect_op.hpp \ asio/detail/reactive_socket_recvfrom_op.hpp \ @@ -467,7 +513,6 @@ nobase_include_HEADERS = \ asio/detail/reactive_socket_service_base.hpp \ asio/detail/reactive_socket_service.hpp \ asio/detail/reactive_wait_op.hpp \ - asio/detail/reactor_fwd.hpp \ asio/detail/reactor.hpp \ asio/detail/reactor_op.hpp \ asio/detail/reactor_op_queue.hpp \ @@ -480,6 +525,7 @@ nobase_include_HEADERS = \ asio/detail/resolver_service.hpp \ asio/detail/scheduler.hpp \ asio/detail/scheduler_operation.hpp \ + asio/detail/scheduler_task.hpp \ asio/detail/scheduler_thread_info.hpp \ asio/detail/scoped_lock.hpp \ asio/detail/scoped_ptr.hpp \ @@ -522,6 +568,7 @@ nobase_include_HEADERS = \ asio/detail/timer_scheduler.hpp \ asio/detail/tss_ptr.hpp \ asio/detail/type_traits.hpp \ + asio/detail/utility.hpp \ asio/detail/variadic_templates.hpp \ asio/detail/wait_handler.hpp \ asio/detail/wait_op.hpp \ @@ -531,6 +578,7 @@ nobase_include_HEADERS = \ asio/detail/win_fd_set_adapter.hpp \ asio/detail/win_fenced_block.hpp \ asio/detail/win_global.hpp \ + asio/detail/win_iocp_file_service.hpp \ asio/detail/win_iocp_handle_read_op.hpp \ asio/detail/win_iocp_handle_service.hpp \ asio/detail/win_iocp_handle_write_op.hpp \ @@ -617,24 +665,45 @@ nobase_include_HEADERS = \ asio/experimental/as_single.hpp \ asio/experimental/as_tuple.hpp \ asio/experimental/awaitable_operators.hpp \ + asio/experimental/basic_channel.hpp \ + asio/experimental/basic_concurrent_channel.hpp \ asio/experimental/cancellation_condition.hpp \ + asio/experimental/channel.hpp \ + asio/experimental/channel_error.hpp \ + asio/experimental/channel_traits.hpp \ + asio/experimental/co_composed.hpp \ + asio/experimental/co_spawn.hpp \ + asio/experimental/concurrent_channel.hpp \ asio/experimental/coro.hpp \ + asio/experimental/coro_traits.hpp \ asio/experimental/deferred.hpp \ - asio/experimental/detail/completion_handler_erasure.hpp \ + asio/experimental/detail/channel_handler.hpp \ + asio/experimental/detail/channel_message.hpp \ + asio/experimental/detail/channel_operation.hpp \ + asio/experimental/detail/channel_payload.hpp \ + asio/experimental/detail/channel_receive_op.hpp \ + asio/experimental/detail/channel_send_functions.hpp \ + asio/experimental/detail/channel_send_op.hpp \ + asio/experimental/detail/channel_service.hpp \ + asio/experimental/detail/coro_completion_handler.hpp \ asio/experimental/detail/coro_promise_allocator.hpp \ - asio/experimental/detail/coro_traits.hpp \ + asio/experimental/detail/has_signature.hpp \ + asio/experimental/detail/impl/channel_service.hpp \ asio/experimental/detail/partial_promise.hpp \ - asio/experimental/impl/append.hpp \ asio/experimental/impl/as_single.hpp \ - asio/experimental/impl/as_tuple.hpp \ - asio/experimental/impl/deferred.hpp \ + asio/experimental/impl/channel_error.ipp \ + asio/experimental/impl/co_composed.hpp \ + asio/experimental/impl/coro.hpp \ asio/experimental/impl/parallel_group.hpp \ - asio/experimental/impl/prepend.hpp \ asio/experimental/impl/promise.hpp \ + asio/experimental/impl/use_coro.hpp \ + asio/experimental/impl/use_promise.hpp \ asio/experimental/parallel_group.hpp \ asio/experimental/prepend.hpp \ asio/experimental/promise.hpp \ asio/experimental/use_coro.hpp \ + asio/experimental/use_promise.hpp \ + asio/file_base.hpp \ asio/generic/basic_endpoint.hpp \ asio/generic/datagram_protocol.hpp \ asio/generic/detail/endpoint.hpp \ @@ -647,15 +716,21 @@ nobase_include_HEADERS = \ asio/handler_invoke_hook.hpp \ asio/high_resolution_timer.hpp \ asio.hpp \ + asio/impl/any_completion_executor.ipp \ + asio/impl/any_io_executor.ipp \ + asio/impl/append.hpp \ + asio/impl/as_tuple.hpp \ asio/impl/awaitable.hpp \ asio/impl/buffered_read_stream.hpp \ asio/impl/buffered_write_stream.hpp \ + asio/impl/cancellation_signal.ipp \ asio/impl/co_spawn.hpp \ - asio/impl/compose.hpp \ asio/impl/connect.hpp \ - asio/impl/defer.hpp \ + asio/impl/connect_pipe.hpp \ + asio/impl/connect_pipe.ipp \ + asio/impl/consign.hpp \ + asio/impl/deferred.hpp \ asio/impl/detached.hpp \ - asio/impl/dispatch.hpp \ asio/impl/error_code.ipp \ asio/impl/error.ipp \ asio/impl/execution_context.hpp \ @@ -666,7 +741,7 @@ nobase_include_HEADERS = \ asio/impl/io_context.hpp \ asio/impl/io_context.ipp \ asio/impl/multiple_exceptions.ipp \ - asio/impl/post.hpp \ + asio/impl/prepend.hpp \ asio/impl/read_at.hpp \ asio/impl/read.hpp \ asio/impl/read_until.hpp \ @@ -729,6 +804,7 @@ nobase_include_HEADERS = \ asio/ip/unicast.hpp \ asio/ip/v6_only.hpp \ asio/is_applicable_property.hpp \ + asio/is_contiguous_iterator.hpp \ asio/is_executor.hpp \ asio/is_read_buffered.hpp \ asio/is_write_buffered.hpp \ @@ -737,6 +813,7 @@ nobase_include_HEADERS = \ asio/local/datagram_protocol.hpp \ asio/local/detail/endpoint.hpp \ asio/local/detail/impl/endpoint.ipp \ + asio/local/seq_packet_protocol.hpp \ asio/local/stream_protocol.hpp \ asio/multiple_exceptions.hpp \ asio/packaged_task.hpp \ @@ -748,15 +825,21 @@ nobase_include_HEADERS = \ asio/posix/stream_descriptor.hpp \ asio/post.hpp \ asio/prefer.hpp \ + asio/prepend.hpp \ asio/query.hpp \ + asio/random_access_file.hpp \ asio/read_at.hpp \ asio/read.hpp \ asio/read_until.hpp \ + asio/readable_pipe.hpp \ + asio/recycling_allocator.hpp \ asio/redirect_error.hpp \ + asio/registered_buffer.hpp \ asio/require.hpp \ asio/require_concept.hpp \ asio/serial_port_base.hpp \ asio/serial_port.hpp \ + asio/signal_set_base.hpp \ asio/signal_set.hpp \ asio/socket_base.hpp \ asio/spawn.hpp \ @@ -794,6 +877,7 @@ nobase_include_HEADERS = \ asio/steady_timer.hpp \ asio/strand.hpp \ asio/streambuf.hpp \ + asio/stream_file.hpp \ asio/system_context.hpp \ asio/system_error.hpp \ asio/system_executor.hpp \ @@ -856,6 +940,7 @@ nobase_include_HEADERS = \ asio/windows/overlapped_ptr.hpp \ asio/windows/random_access_handle.hpp \ asio/windows/stream_handle.hpp \ + asio/writable_pipe.hpp \ asio/write_at.hpp \ asio/write.hpp \ asio/yield.hpp @@ -971,7 +1056,6 @@ cscopelist-am: $(am__tagged_files) distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am diff --git a/external_libraries/asio/include/asio.hpp b/external_libraries/asio/include/asio.hpp index 94db21e8..a973ab17 100644 --- a/external_libraries/asio/include/asio.hpp +++ b/external_libraries/asio/include/asio.hpp @@ -2,7 +2,7 @@ // asio.hpp // ~~~~~~~~ // -// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -15,16 +15,25 @@ # pragma once #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) +#include "asio/any_completion_executor.hpp" +#include "asio/any_completion_handler.hpp" +#include "asio/any_io_executor.hpp" +#include "asio/append.hpp" +#include "asio/as_tuple.hpp" #include "asio/associated_allocator.hpp" -#include "asio/associated_executor.hpp" #include "asio/associated_cancellation_slot.hpp" +#include "asio/associated_executor.hpp" +#include "asio/associated_immediate_executor.hpp" #include "asio/associator.hpp" #include "asio/async_result.hpp" #include "asio/awaitable.hpp" #include "asio/basic_datagram_socket.hpp" #include "asio/basic_deadline_timer.hpp" +#include "asio/basic_file.hpp" #include "asio/basic_io_object.hpp" +#include "asio/basic_random_access_file.hpp" #include "asio/basic_raw_socket.hpp" +#include "asio/basic_readable_pipe.hpp" #include "asio/basic_seq_packet_socket.hpp" #include "asio/basic_serial_port.hpp" #include "asio/basic_signal_set.hpp" @@ -32,12 +41,17 @@ #include "asio/basic_socket_acceptor.hpp" #include "asio/basic_socket_iostream.hpp" #include "asio/basic_socket_streambuf.hpp" +#include "asio/basic_stream_file.hpp" #include "asio/basic_stream_socket.hpp" #include "asio/basic_streambuf.hpp" #include "asio/basic_waitable_timer.hpp" +#include "asio/basic_writable_pipe.hpp" +#include "asio/bind_allocator.hpp" #include "asio/bind_cancellation_slot.hpp" #include "asio/bind_executor.hpp" +#include "asio/bind_immediate_executor.hpp" #include "asio/buffer.hpp" +#include "asio/buffer_registration.hpp" #include "asio/buffered_read_stream_fwd.hpp" #include "asio/buffered_read_stream.hpp" #include "asio/buffered_stream_fwd.hpp" @@ -52,9 +66,12 @@ #include "asio/completion_condition.hpp" #include "asio/compose.hpp" #include "asio/connect.hpp" +#include "asio/connect_pipe.hpp" +#include "asio/consign.hpp" #include "asio/coroutine.hpp" #include "asio/deadline_timer.hpp" #include "asio/defer.hpp" +#include "asio/deferred.hpp" #include "asio/detached.hpp" #include "asio/dispatch.hpp" #include "asio/error.hpp" @@ -90,6 +107,7 @@ #include "asio/execution_context.hpp" #include "asio/executor.hpp" #include "asio/executor_work_guard.hpp" +#include "asio/file_base.hpp" #include "asio/generic/basic_endpoint.hpp" #include "asio/generic/datagram_protocol.hpp" #include "asio/generic/raw_protocol.hpp" @@ -128,12 +146,14 @@ #include "asio/ip/unicast.hpp" #include "asio/ip/v6_only.hpp" #include "asio/is_applicable_property.hpp" +#include "asio/is_contiguous_iterator.hpp" #include "asio/is_executor.hpp" #include "asio/is_read_buffered.hpp" #include "asio/is_write_buffered.hpp" #include "asio/local/basic_endpoint.hpp" #include "asio/local/connect_pair.hpp" #include "asio/local/datagram_protocol.hpp" +#include "asio/local/seq_packet_protocol.hpp" #include "asio/local/stream_protocol.hpp" #include "asio/multiple_exceptions.hpp" #include "asio/packaged_task.hpp" @@ -145,20 +165,27 @@ #include "asio/posix/stream_descriptor.hpp" #include "asio/post.hpp" #include "asio/prefer.hpp" +#include "asio/prepend.hpp" #include "asio/query.hpp" +#include "asio/random_access_file.hpp" #include "asio/read.hpp" #include "asio/read_at.hpp" #include "asio/read_until.hpp" +#include "asio/readable_pipe.hpp" +#include "asio/recycling_allocator.hpp" #include "asio/redirect_error.hpp" +#include "asio/registered_buffer.hpp" #include "asio/require.hpp" #include "asio/require_concept.hpp" #include "asio/serial_port.hpp" #include "asio/serial_port_base.hpp" #include "asio/signal_set.hpp" +#include "asio/signal_set_base.hpp" #include "asio/socket_base.hpp" #include "asio/static_thread_pool.hpp" #include "asio/steady_timer.hpp" #include "asio/strand.hpp" +#include "asio/stream_file.hpp" #include "asio/streambuf.hpp" #include "asio/system_context.hpp" #include "asio/system_error.hpp" @@ -182,6 +209,7 @@ #include "asio/windows/overlapped_ptr.hpp" #include "asio/windows/random_access_handle.hpp" #include "asio/windows/stream_handle.hpp" +#include "asio/writable_pipe.hpp" #include "asio/write.hpp" #include "asio/write_at.hpp" diff --git a/external_libraries/asio/include/asio/any_completion_executor.hpp b/external_libraries/asio/include/asio/any_completion_executor.hpp new file mode 100644 index 00000000..420927cc --- /dev/null +++ b/external_libraries/asio/include/asio/any_completion_executor.hpp @@ -0,0 +1,342 @@ +// +// any_completion_executor.hpp +// ~~~~~~~~~~~~~~~~~~~~~~~~~~~ +// +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// +// Distributed under the Boost Software License, Version 1.0. (See accompanying +// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +// + +#ifndef ASIO_ANY_COMPLETION_EXECUTOR_HPP +#define ASIO_ANY_COMPLETION_EXECUTOR_HPP + +#if defined(_MSC_VER) && (_MSC_VER >= 1200) +# pragma once +#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) + +#include "asio/detail/config.hpp" +#if defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) +# include "asio/executor.hpp" +#else // defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) +# include "asio/execution.hpp" +#endif // defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) + +#include "asio/detail/push_options.hpp" + +namespace asio { + +#if defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) + +typedef executor any_completion_executor; + +#else // defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) + +/// Polymorphic executor type for use with I/O objects. +/** + * The @c any_completion_executor type is a polymorphic executor that supports + * the set of properties required for the execution of completion handlers. It + * is defined as the execution::any_executor class template parameterised as + * follows: + * @code execution::any_executor< + * execution::prefer_only, + * execution::prefer_only + * execution::prefer_only, + * execution::prefer_only + * > @endcode + */ +class any_completion_executor : +#if defined(GENERATING_DOCUMENTATION) + public execution::any_executor<...> +#else // defined(GENERATING_DOCUMENTATION) + public execution::any_executor< + execution::prefer_only, + execution::prefer_only, + execution::prefer_only, + execution::prefer_only + > +#endif // defined(GENERATING_DOCUMENTATION) +{ +public: +#if !defined(GENERATING_DOCUMENTATION) + typedef execution::any_executor< + execution::prefer_only, + execution::prefer_only, + execution::prefer_only, + execution::prefer_only + > base_type; + + typedef void supportable_properties_type( + execution::prefer_only, + execution::prefer_only, + execution::prefer_only, + execution::prefer_only + ); +#endif // !defined(GENERATING_DOCUMENTATION) + + /// Default constructor. + ASIO_DECL any_completion_executor() ASIO_NOEXCEPT; + + /// Construct in an empty state. Equivalent effects to default constructor. + ASIO_DECL any_completion_executor(nullptr_t) ASIO_NOEXCEPT; + + /// Copy constructor. + ASIO_DECL any_completion_executor( + const any_completion_executor& e) ASIO_NOEXCEPT; + +#if defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + /// Move constructor. + ASIO_DECL any_completion_executor( + any_completion_executor&& e) ASIO_NOEXCEPT; +#endif // defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + + /// Construct to point to the same target as another any_executor. +#if defined(GENERATING_DOCUMENTATION) + template + any_completion_executor( + execution::any_executor e); +#else // defined(GENERATING_DOCUMENTATION) + template + any_completion_executor(OtherAnyExecutor e, + typename constraint< + conditional< + !is_same::value + && is_base_of::value, + typename execution::detail::supportable_properties< + 0, supportable_properties_type>::template + is_valid_target, + false_type + >::type::value + >::type = 0) + : base_type(ASIO_MOVE_CAST(OtherAnyExecutor)(e)) + { + } +#endif // defined(GENERATING_DOCUMENTATION) + + /// Construct to point to the same target as another any_executor. +#if defined(GENERATING_DOCUMENTATION) + template + any_completion_executor(std::nothrow_t, + execution::any_executor e); +#else // defined(GENERATING_DOCUMENTATION) + template + any_completion_executor(std::nothrow_t, OtherAnyExecutor e, + typename constraint< + conditional< + !is_same::value + && is_base_of::value, + typename execution::detail::supportable_properties< + 0, supportable_properties_type>::template + is_valid_target, + false_type + >::type::value + >::type = 0) ASIO_NOEXCEPT + : base_type(std::nothrow, ASIO_MOVE_CAST(OtherAnyExecutor)(e)) + { + } +#endif // defined(GENERATING_DOCUMENTATION) + + /// Construct to point to the same target as another any_executor. + ASIO_DECL any_completion_executor(std::nothrow_t, + const any_completion_executor& e) ASIO_NOEXCEPT; + +#if defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + /// Construct to point to the same target as another any_executor. + ASIO_DECL any_completion_executor(std::nothrow_t, + any_completion_executor&& e) ASIO_NOEXCEPT; +#endif // defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + + /// Construct a polymorphic wrapper for the specified executor. +#if defined(GENERATING_DOCUMENTATION) + template + any_completion_executor(Executor e); +#else // defined(GENERATING_DOCUMENTATION) + template + any_completion_executor(Executor e, + typename constraint< + conditional< + !is_same::value + && !is_base_of::value, + execution::detail::is_valid_target_executor< + Executor, supportable_properties_type>, + false_type + >::type::value + >::type = 0) + : base_type(ASIO_MOVE_CAST(Executor)(e)) + { + } +#endif // defined(GENERATING_DOCUMENTATION) + + /// Construct a polymorphic wrapper for the specified executor. +#if defined(GENERATING_DOCUMENTATION) + template + any_completion_executor(std::nothrow_t, Executor e); +#else // defined(GENERATING_DOCUMENTATION) + template + any_completion_executor(std::nothrow_t, Executor e, + typename constraint< + conditional< + !is_same::value + && !is_base_of::value, + execution::detail::is_valid_target_executor< + Executor, supportable_properties_type>, + false_type + >::type::value + >::type = 0) ASIO_NOEXCEPT + : base_type(std::nothrow, ASIO_MOVE_CAST(Executor)(e)) + { + } +#endif // defined(GENERATING_DOCUMENTATION) + + /// Assignment operator. + ASIO_DECL any_completion_executor& operator=( + const any_completion_executor& e) ASIO_NOEXCEPT; + +#if defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + /// Move assignment operator. + ASIO_DECL any_completion_executor& operator=( + any_completion_executor&& e) ASIO_NOEXCEPT; +#endif // defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + + /// Assignment operator that sets the polymorphic wrapper to the empty state. + ASIO_DECL any_completion_executor& operator=(nullptr_t); + + /// Destructor. + ASIO_DECL ~any_completion_executor(); + + /// Swap targets with another polymorphic wrapper. + ASIO_DECL void swap(any_completion_executor& other) ASIO_NOEXCEPT; + + /// Obtain a polymorphic wrapper with the specified property. + /** + * Do not call this function directly. It is intended for use with the + * asio::require and asio::prefer customisation points. + * + * For example: + * @code any_completion_executor ex = ...; + * auto ex2 = asio::require(ex, execution::relationship.fork); @endcode + */ + template + any_completion_executor require(const Property& p, + typename constraint< + traits::require_member::is_valid + >::type = 0) const + { + return static_cast(*this).require(p); + } + + /// Obtain a polymorphic wrapper with the specified property. + /** + * Do not call this function directly. It is intended for use with the + * asio::prefer customisation point. + * + * For example: + * @code any_completion_executor ex = ...; + * auto ex2 = asio::prefer(ex, execution::relationship.fork); @endcode + */ + template + any_completion_executor prefer(const Property& p, + typename constraint< + traits::prefer_member::is_valid + >::type = 0) const + { + return static_cast(*this).prefer(p); + } +}; + +#if !defined(GENERATING_DOCUMENTATION) + +template <> +ASIO_DECL any_completion_executor any_completion_executor::prefer( + const execution::outstanding_work_t::tracked_t&, int) const; + +template <> +ASIO_DECL any_completion_executor any_completion_executor::prefer( + const execution::outstanding_work_t::untracked_t&, int) const; + +template <> +ASIO_DECL any_completion_executor any_completion_executor::prefer( + const execution::relationship_t::fork_t&, int) const; + +template <> +ASIO_DECL any_completion_executor any_completion_executor::prefer( + const execution::relationship_t::continuation_t&, int) const; + +namespace traits { + +#if !defined(ASIO_HAS_DEDUCED_EQUALITY_COMPARABLE_TRAIT) + +template <> +struct equality_comparable +{ + static const bool is_valid = true; + static const bool is_noexcept = true; +}; + +#endif // !defined(ASIO_HAS_DEDUCED_EQUALITY_COMPARABLE_TRAIT) + +#if !defined(ASIO_HAS_DEDUCED_EXECUTE_MEMBER_TRAIT) + +template +struct execute_member +{ + static const bool is_valid = true; + static const bool is_noexcept = false; + typedef void result_type; +}; + +#endif // !defined(ASIO_HAS_DEDUCED_EXECUTE_MEMBER_TRAIT) + +#if !defined(ASIO_HAS_DEDUCED_QUERY_MEMBER_TRAIT) + +template +struct query_member : + query_member +{ +}; + +#endif // !defined(ASIO_HAS_DEDUCED_QUERY_MEMBER_TRAIT) + +#if !defined(ASIO_HAS_DEDUCED_REQUIRE_MEMBER_TRAIT) + +template +struct require_member : + require_member +{ + typedef any_completion_executor result_type; +}; + +#endif // !defined(ASIO_HAS_DEDUCED_REQUIRE_MEMBER_TRAIT) + +#if !defined(ASIO_HAS_DEDUCED_PREFER_MEMBER_TRAIT) + +template +struct prefer_member : + prefer_member +{ + typedef any_completion_executor result_type; +}; + +#endif // !defined(ASIO_HAS_DEDUCED_PREFER_MEMBER_TRAIT) + +} // namespace traits + +#endif // !defined(GENERATING_DOCUMENTATION) + +#endif // defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) + +} // namespace asio + +#include "asio/detail/pop_options.hpp" + +#if defined(ASIO_HEADER_ONLY) \ + && !defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) +# include "asio/impl/any_completion_executor.ipp" +#endif // defined(ASIO_HEADER_ONLY) + // && !defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) + +#endif // ASIO_ANY_COMPLETION_EXECUTOR_HPP diff --git a/external_libraries/asio/include/asio/any_completion_handler.hpp b/external_libraries/asio/include/asio/any_completion_handler.hpp new file mode 100644 index 00000000..cd114537 --- /dev/null +++ b/external_libraries/asio/include/asio/any_completion_handler.hpp @@ -0,0 +1,762 @@ +// +// any_completion_handler.hpp +// ~~~~~~~~~~~~~~~~~~~~~~~~~~ +// +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// +// Distributed under the Boost Software License, Version 1.0. (See accompanying +// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +// + +#ifndef ASIO_ANY_COMPLETION_HANDLER_HPP +#define ASIO_ANY_COMPLETION_HANDLER_HPP + +#include "asio/detail/config.hpp" + +#if (defined(ASIO_HAS_STD_TUPLE) \ + && defined(ASIO_HAS_MOVE) \ + && defined(ASIO_HAS_VARIADIC_TEMPLATES)) \ + || defined(GENERATING_DOCUMENTATION) + +#include +#include +#include +#include +#include "asio/any_completion_executor.hpp" +#include "asio/associated_allocator.hpp" +#include "asio/associated_cancellation_slot.hpp" +#include "asio/associated_executor.hpp" +#include "asio/cancellation_state.hpp" +#include "asio/recycling_allocator.hpp" + +#include "asio/detail/push_options.hpp" + +namespace asio { +namespace detail { + +class any_completion_handler_impl_base +{ +public: + template + explicit any_completion_handler_impl_base(S&& slot) + : cancel_state_(ASIO_MOVE_CAST(S)(slot), enable_total_cancellation()) + { + } + + cancellation_slot get_cancellation_slot() const ASIO_NOEXCEPT + { + return cancel_state_.slot(); + } + +private: + cancellation_state cancel_state_; +}; + +template +class any_completion_handler_impl : + public any_completion_handler_impl_base +{ +public: + template + any_completion_handler_impl(S&& slot, H&& h) + : any_completion_handler_impl_base(ASIO_MOVE_CAST(S)(slot)), + handler_(ASIO_MOVE_CAST(H)(h)) + { + } + + struct uninit_deleter + { + typename std::allocator_traits< + associated_allocator_t>>::template + rebind_alloc alloc; + + void operator()(any_completion_handler_impl* ptr) + { + std::allocator_traits::deallocate(alloc, ptr, 1); + } + }; + + struct deleter + { + typename std::allocator_traits< + associated_allocator_t>>::template + rebind_alloc alloc; + + void operator()(any_completion_handler_impl* ptr) + { + std::allocator_traits::destroy(alloc, ptr); + std::allocator_traits::deallocate(alloc, ptr, 1); + } + }; + + template + static any_completion_handler_impl* create(S&& slot, H&& h) + { + uninit_deleter d{ + (get_associated_allocator)(h, + asio::recycling_allocator())}; + + std::unique_ptr uninit_ptr( + std::allocator_traits::allocate(d.alloc, 1), d); + + any_completion_handler_impl* ptr = + new (uninit_ptr.get()) any_completion_handler_impl( + ASIO_MOVE_CAST(S)(slot), ASIO_MOVE_CAST(H)(h)); + + uninit_ptr.release(); + return ptr; + } + + void destroy() + { + deleter d{ + (get_associated_allocator)(handler_, + asio::recycling_allocator())}; + + d(this); + } + + any_completion_executor executor( + const any_completion_executor& candidate) const ASIO_NOEXCEPT + { + return any_completion_executor(std::nothrow, + (get_associated_executor)(handler_, candidate)); + } + + void* allocate(std::size_t size, std::size_t align) const + { + typename std::allocator_traits< + associated_allocator_t>>::template + rebind_alloc alloc( + (get_associated_allocator)(handler_, + asio::recycling_allocator())); + + std::size_t space = size + align - 1; + unsigned char* base = + std::allocator_traits::allocate( + alloc, space + sizeof(std::ptrdiff_t)); + + void* p = base; + if (detail::align(align, size, p, space)) + { + std::ptrdiff_t off = static_cast(p) - base; + std::memcpy(static_cast(p) + size, &off, sizeof(off)); + return p; + } + + std::bad_alloc ex; + asio::detail::throw_exception(ex); + return nullptr; + } + + void deallocate(void* p, std::size_t size, std::size_t align) const + { + if (p) + { + typename std::allocator_traits< + associated_allocator_t>>::template + rebind_alloc alloc( + (get_associated_allocator)(handler_, + asio::recycling_allocator())); + + std::ptrdiff_t off; + std::memcpy(&off, static_cast(p) + size, sizeof(off)); + unsigned char* base = static_cast(p) - off; + + std::allocator_traits::deallocate( + alloc, base, size + align -1 + sizeof(std::ptrdiff_t)); + } + } + + template + void call(Args&&... args) + { + deleter d{ + (get_associated_allocator)(handler_, + asio::recycling_allocator())}; + + std::unique_ptr ptr(this, d); + Handler handler(ASIO_MOVE_CAST(Handler)(handler_)); + ptr.reset(); + + ASIO_MOVE_CAST(Handler)(handler)( + ASIO_MOVE_CAST(Args)(args)...); + } + +private: + Handler handler_; +}; + +template +class any_completion_handler_call_fn; + +template +class any_completion_handler_call_fn +{ +public: + using type = void(*)(any_completion_handler_impl_base*, Args...); + + constexpr any_completion_handler_call_fn(type fn) + : call_fn_(fn) + { + } + + void call(any_completion_handler_impl_base* impl, Args... args) const + { + call_fn_(impl, ASIO_MOVE_CAST(Args)(args)...); + } + + template + static void impl(any_completion_handler_impl_base* impl, Args... args) + { + static_cast*>(impl)->call( + ASIO_MOVE_CAST(Args)(args)...); + } + +private: + type call_fn_; +}; + +template +class any_completion_handler_call_fns; + +template +class any_completion_handler_call_fns : + public any_completion_handler_call_fn +{ +public: + using any_completion_handler_call_fn< + Signature>::any_completion_handler_call_fn; + using any_completion_handler_call_fn::call; +}; + +template +class any_completion_handler_call_fns : + public any_completion_handler_call_fn, + public any_completion_handler_call_fns +{ +public: + template + constexpr any_completion_handler_call_fns(CallFn fn, CallFns... fns) + : any_completion_handler_call_fn(fn), + any_completion_handler_call_fns(fns...) + { + } + + using any_completion_handler_call_fn::call; + using any_completion_handler_call_fns::call; +}; + +class any_completion_handler_destroy_fn +{ +public: + using type = void(*)(any_completion_handler_impl_base*); + + constexpr any_completion_handler_destroy_fn(type fn) + : destroy_fn_(fn) + { + } + + void destroy(any_completion_handler_impl_base* impl) const + { + destroy_fn_(impl); + } + + template + static void impl(any_completion_handler_impl_base* impl) + { + static_cast*>(impl)->destroy(); + } + +private: + type destroy_fn_; +}; + +class any_completion_handler_executor_fn +{ +public: + using type = any_completion_executor(*)( + any_completion_handler_impl_base*, const any_completion_executor&); + + constexpr any_completion_handler_executor_fn(type fn) + : executor_fn_(fn) + { + } + + any_completion_executor executor(any_completion_handler_impl_base* impl, + const any_completion_executor& candidate) const + { + return executor_fn_(impl, candidate); + } + + template + static any_completion_executor impl(any_completion_handler_impl_base* impl, + const any_completion_executor& candidate) + { + return static_cast*>(impl)->executor( + candidate); + } + +private: + type executor_fn_; +}; + +class any_completion_handler_allocate_fn +{ +public: + using type = void*(*)(any_completion_handler_impl_base*, + std::size_t, std::size_t); + + constexpr any_completion_handler_allocate_fn(type fn) + : allocate_fn_(fn) + { + } + + void* allocate(any_completion_handler_impl_base* impl, + std::size_t size, std::size_t align) const + { + return allocate_fn_(impl, size, align); + } + + template + static void* impl(any_completion_handler_impl_base* impl, + std::size_t size, std::size_t align) + { + return static_cast*>(impl)->allocate( + size, align); + } + +private: + type allocate_fn_; +}; + +class any_completion_handler_deallocate_fn +{ +public: + using type = void(*)(any_completion_handler_impl_base*, + void*, std::size_t, std::size_t); + + constexpr any_completion_handler_deallocate_fn(type fn) + : deallocate_fn_(fn) + { + } + + void deallocate(any_completion_handler_impl_base* impl, + void* p, std::size_t size, std::size_t align) const + { + deallocate_fn_(impl, p, size, align); + } + + template + static void impl(any_completion_handler_impl_base* impl, + void* p, std::size_t size, std::size_t align) + { + static_cast*>(impl)->deallocate( + p, size, align); + } + +private: + type deallocate_fn_; +}; + +template +class any_completion_handler_fn_table + : private any_completion_handler_destroy_fn, + private any_completion_handler_executor_fn, + private any_completion_handler_allocate_fn, + private any_completion_handler_deallocate_fn, + private any_completion_handler_call_fns +{ +public: + template + constexpr any_completion_handler_fn_table( + any_completion_handler_destroy_fn::type destroy_fn, + any_completion_handler_executor_fn::type executor_fn, + any_completion_handler_allocate_fn::type allocate_fn, + any_completion_handler_deallocate_fn::type deallocate_fn, + CallFns... call_fns) + : any_completion_handler_destroy_fn(destroy_fn), + any_completion_handler_executor_fn(executor_fn), + any_completion_handler_allocate_fn(allocate_fn), + any_completion_handler_deallocate_fn(deallocate_fn), + any_completion_handler_call_fns(call_fns...) + { + } + + using any_completion_handler_destroy_fn::destroy; + using any_completion_handler_executor_fn::executor; + using any_completion_handler_allocate_fn::allocate; + using any_completion_handler_deallocate_fn::deallocate; + using any_completion_handler_call_fns::call; +}; + +template +struct any_completion_handler_fn_table_instance +{ + static constexpr any_completion_handler_fn_table + value = any_completion_handler_fn_table( + &any_completion_handler_destroy_fn::impl, + &any_completion_handler_executor_fn::impl, + &any_completion_handler_allocate_fn::impl, + &any_completion_handler_deallocate_fn::impl, + &any_completion_handler_call_fn::template impl...); +}; + +template +constexpr any_completion_handler_fn_table +any_completion_handler_fn_table_instance::value; + +} // namespace detail + +template +class any_completion_handler; + +/// An allocator type that forwards memory allocation operations through an +/// instance of @c any_completion_handler. +template +class any_completion_handler_allocator +{ +private: + template + friend class any_completion_handler; + + template + friend class any_completion_handler_allocator; + + const detail::any_completion_handler_fn_table* fn_table_; + detail::any_completion_handler_impl_base* impl_; + + constexpr any_completion_handler_allocator(int, + const any_completion_handler& h) ASIO_NOEXCEPT + : fn_table_(h.fn_table_), + impl_(h.impl_) + { + } + +public: + /// The type of objects that may be allocated by the allocator. + typedef T value_type; + + /// Rebinds an allocator to another value type. + template + struct rebind + { + /// Specifies the type of the rebound allocator. + typedef any_completion_handler_allocator other; + }; + + /// Construct from another @c any_completion_handler_allocator. + template + constexpr any_completion_handler_allocator( + const any_completion_handler_allocator& a) + ASIO_NOEXCEPT + : fn_table_(a.fn_table_), + impl_(a.impl_) + { + } + + /// Equality operator. + constexpr bool operator==( + const any_completion_handler_allocator& other) const ASIO_NOEXCEPT + { + return fn_table_ == other.fn_table_ && impl_ == other.impl_; + } + + /// Inequality operator. + constexpr bool operator!=( + const any_completion_handler_allocator& other) const ASIO_NOEXCEPT + { + return fn_table_ != other.fn_table_ || impl_ != other.impl_; + } + + /// Allocate space for @c n objects of the allocator's value type. + T* allocate(std::size_t n) const + { + return static_cast( + fn_table_->allocate( + impl_, sizeof(T) * n, alignof(T))); + } + + /// Deallocate space for @c n objects of the allocator's value type. + void deallocate(T* p, std::size_t n) const + { + fn_table_->deallocate(impl_, p, sizeof(T) * n, alignof(T)); + } +}; + +/// A protoco-allocator type that may be rebound to obtain an allocator that +/// forwards memory allocation operations through an instance of +/// @c any_completion_handler. +template +class any_completion_handler_allocator +{ +private: + template + friend class any_completion_handler; + + template + friend class any_completion_handler_allocator; + + const detail::any_completion_handler_fn_table* fn_table_; + detail::any_completion_handler_impl_base* impl_; + + constexpr any_completion_handler_allocator(int, + const any_completion_handler& h) ASIO_NOEXCEPT + : fn_table_(h.fn_table_), + impl_(h.impl_) + { + } + +public: + /// @c void as no objects can be allocated through a proto-allocator. + typedef void value_type; + + /// Rebinds an allocator to another value type. + template + struct rebind + { + /// Specifies the type of the rebound allocator. + typedef any_completion_handler_allocator other; + }; + + /// Construct from another @c any_completion_handler_allocator. + template + constexpr any_completion_handler_allocator( + const any_completion_handler_allocator& a) + ASIO_NOEXCEPT + : fn_table_(a.fn_table_), + impl_(a.impl_) + { + } + + /// Equality operator. + constexpr bool operator==( + const any_completion_handler_allocator& other) const ASIO_NOEXCEPT + { + return fn_table_ == other.fn_table_ && impl_ == other.impl_; + } + + /// Inequality operator. + constexpr bool operator!=( + const any_completion_handler_allocator& other) const ASIO_NOEXCEPT + { + return fn_table_ != other.fn_table_ || impl_ != other.impl_; + } +}; + +/// Polymorphic wrapper for completion handlers. +/** + * The @c any_completion_handler class template is a polymorphic wrapper for + * completion handlers that propagates the associated executor, associated + * allocator, and associated cancellation slot through a type-erasing interface. + * + * When using @c any_completion_handler, specify one or more completion + * signatures as template parameters. These will dictate the arguments that may + * be passed to the handler through the polymorphic interface. + * + * Typical uses for @c any_completion_handler include: + * + * @li Separate compilation of asynchronous operation implementations. + * + * @li Enabling interoperability between asynchronous operations and virtual + * functions. + */ +template +class any_completion_handler +{ +#if !defined(GENERATING_DOCUMENTATION) +private: + template + friend class any_completion_handler_allocator; + + template + friend struct associated_executor; + + const detail::any_completion_handler_fn_table* fn_table_; + detail::any_completion_handler_impl_base* impl_; +#endif // !defined(GENERATING_DOCUMENTATION) + +public: + /// The associated allocator type. + using allocator_type = any_completion_handler_allocator; + + /// The associated cancellation slot type. + using cancellation_slot_type = cancellation_slot; + + /// Construct an @c any_completion_handler in an empty state, without a target + /// object. + constexpr any_completion_handler() + : fn_table_(nullptr), + impl_(nullptr) + { + } + + /// Construct an @c any_completion_handler in an empty state, without a target + /// object. + constexpr any_completion_handler(nullptr_t) + : fn_table_(nullptr), + impl_(nullptr) + { + } + + /// Construct an @c any_completion_handler to contain the specified target. + template ::type> + any_completion_handler(H&& h, + typename constraint< + !is_same::type, any_completion_handler>::value + >::type = 0) + : fn_table_( + &detail::any_completion_handler_fn_table_instance< + Handler, Signatures...>::value), + impl_(detail::any_completion_handler_impl::create( + (get_associated_cancellation_slot)(h), ASIO_MOVE_CAST(H)(h))) + { + } + + /// Move-construct an @c any_completion_handler from another. + /** + * After the operation, the moved-from object @c other has no target. + */ + any_completion_handler(any_completion_handler&& other) ASIO_NOEXCEPT + : fn_table_(other.fn_table_), + impl_(other.impl_) + { + other.fn_table_ = nullptr; + other.impl_ = nullptr; + } + + /// Move-assign an @c any_completion_handler from another. + /** + * After the operation, the moved-from object @c other has no target. + */ + any_completion_handler& operator=( + any_completion_handler&& other) ASIO_NOEXCEPT + { + any_completion_handler( + ASIO_MOVE_CAST(any_completion_handler)(other)).swap(*this); + return *this; + } + + /// Assignment operator that sets the polymorphic wrapper to the empty state. + any_completion_handler& operator=(nullptr_t) ASIO_NOEXCEPT + { + any_completion_handler().swap(*this); + return *this; + } + + /// Destructor. + ~any_completion_handler() + { + if (impl_) + fn_table_->destroy(impl_); + } + + /// Test if the polymorphic wrapper is empty. + constexpr explicit operator bool() const ASIO_NOEXCEPT + { + return impl_ != nullptr; + } + + /// Test if the polymorphic wrapper is non-empty. + constexpr bool operator!() const ASIO_NOEXCEPT + { + return impl_ == nullptr; + } + + /// Swap the content of an @c any_completion_handler with another. + void swap(any_completion_handler& other) ASIO_NOEXCEPT + { + std::swap(fn_table_, other.fn_table_); + std::swap(impl_, other.impl_); + } + + /// Get the associated allocator. + allocator_type get_allocator() const ASIO_NOEXCEPT + { + return allocator_type(0, *this); + } + + /// Get the associated cancellation slot. + cancellation_slot_type get_cancellation_slot() const ASIO_NOEXCEPT + { + return impl_->get_cancellation_slot(); + } + + /// Function call operator. + /** + * Invokes target completion handler with the supplied arguments. + * + * This function may only be called once, as the target handler is moved from. + * The polymorphic wrapper is left in an empty state. + * + * Throws @c std::bad_function_call if the polymorphic wrapper is empty. + */ + template + auto operator()(Args&&... args) + -> decltype(fn_table_->call(impl_, ASIO_MOVE_CAST(Args)(args)...)) + { + if (detail::any_completion_handler_impl_base* impl = impl_) + { + impl_ = nullptr; + return fn_table_->call(impl, ASIO_MOVE_CAST(Args)(args)...); + } + std::bad_function_call ex; + asio::detail::throw_exception(ex); + } + + /// Equality operator. + friend constexpr bool operator==( + const any_completion_handler& a, nullptr_t) ASIO_NOEXCEPT + { + return a.impl_ == nullptr; + } + + /// Equality operator. + friend constexpr bool operator==( + nullptr_t, const any_completion_handler& b) ASIO_NOEXCEPT + { + return nullptr == b.impl_; + } + + /// Inequality operator. + friend constexpr bool operator!=( + const any_completion_handler& a, nullptr_t) ASIO_NOEXCEPT + { + return a.impl_ != nullptr; + } + + /// Inequality operator. + friend constexpr bool operator!=( + nullptr_t, const any_completion_handler& b) ASIO_NOEXCEPT + { + return nullptr != b.impl_; + } +}; + +template +struct associated_executor, Candidate> +{ + using type = any_completion_executor; + + static type get(const any_completion_handler& handler, + const Candidate& candidate = Candidate()) ASIO_NOEXCEPT + { + return handler.fn_table_->executor(handler.impl_, + any_completion_executor(std::nothrow, candidate)); + } +}; + +} // namespace asio + +#include "asio/detail/pop_options.hpp" + +#endif // (defined(ASIO_HAS_STD_TUPLE) + // && defined(ASIO_HAS_MOVE) + // && defined(ASIO_HAS_VARIADIC_TEMPLATES)) + // || defined(GENERATING_DOCUMENTATION) + +#endif // ASIO_ANY_COMPLETION_HANDLER_HPP diff --git a/external_libraries/asio/include/asio/any_io_executor.hpp b/external_libraries/asio/include/asio/any_io_executor.hpp index 5f2c13f0..7a77c90d 100644 --- a/external_libraries/asio/include/asio/any_io_executor.hpp +++ b/external_libraries/asio/include/asio/any_io_executor.hpp @@ -2,7 +2,7 @@ // any_io_executor.hpp // ~~~~~~~~~~~~~~~~~~~ // -// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -87,29 +87,17 @@ class any_io_executor : #endif // !defined(GENERATING_DOCUMENTATION) /// Default constructor. - any_io_executor() ASIO_NOEXCEPT - : base_type() - { - } + ASIO_DECL any_io_executor() ASIO_NOEXCEPT; /// Construct in an empty state. Equivalent effects to default constructor. - any_io_executor(nullptr_t) ASIO_NOEXCEPT - : base_type(nullptr_t()) - { - } + ASIO_DECL any_io_executor(nullptr_t) ASIO_NOEXCEPT; /// Copy constructor. - any_io_executor(const any_io_executor& e) ASIO_NOEXCEPT - : base_type(static_cast(e)) - { - } + ASIO_DECL any_io_executor(const any_io_executor& e) ASIO_NOEXCEPT; #if defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) /// Move constructor. - any_io_executor(any_io_executor&& e) ASIO_NOEXCEPT - : base_type(static_cast(e)) - { - } + ASIO_DECL any_io_executor(any_io_executor&& e) ASIO_NOEXCEPT; #endif // defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) /// Construct to point to the same target as another any_executor. @@ -135,6 +123,40 @@ class any_io_executor : } #endif // defined(GENERATING_DOCUMENTATION) + /// Construct to point to the same target as another any_executor. +#if defined(GENERATING_DOCUMENTATION) + template + any_io_executor(std::nothrow_t, + execution::any_executor e); +#else // defined(GENERATING_DOCUMENTATION) + template + any_io_executor(std::nothrow_t, OtherAnyExecutor e, + typename constraint< + conditional< + !is_same::value + && is_base_of::value, + typename execution::detail::supportable_properties< + 0, supportable_properties_type>::template + is_valid_target, + false_type + >::type::value + >::type = 0) ASIO_NOEXCEPT + : base_type(std::nothrow, ASIO_MOVE_CAST(OtherAnyExecutor)(e)) + { + } +#endif // defined(GENERATING_DOCUMENTATION) + + /// Construct to point to the same target as another any_executor. + ASIO_DECL any_io_executor(std::nothrow_t, + const any_io_executor& e) ASIO_NOEXCEPT; + +#if defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + /// Construct to point to the same target as another any_executor. + ASIO_DECL any_io_executor(std::nothrow_t, + any_io_executor&& e) ASIO_NOEXCEPT; +#endif // defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) + /// Construct a polymorphic wrapper for the specified executor. #if defined(GENERATING_DOCUMENTATION) template @@ -157,39 +179,46 @@ class any_io_executor : } #endif // defined(GENERATING_DOCUMENTATION) - /// Assignment operator. - any_io_executor& operator=(const any_io_executor& e) ASIO_NOEXCEPT + /// Construct a polymorphic wrapper for the specified executor. +#if defined(GENERATING_DOCUMENTATION) + template + any_io_executor(std::nothrow_t, Executor e); +#else // defined(GENERATING_DOCUMENTATION) + template + any_io_executor(std::nothrow_t, Executor e, + typename constraint< + conditional< + !is_same::value + && !is_base_of::value, + execution::detail::is_valid_target_executor< + Executor, supportable_properties_type>, + false_type + >::type::value + >::type = 0) ASIO_NOEXCEPT + : base_type(std::nothrow, ASIO_MOVE_CAST(Executor)(e)) { - base_type::operator=(static_cast(e)); - return *this; } +#endif // defined(GENERATING_DOCUMENTATION) + + /// Assignment operator. + ASIO_DECL any_io_executor& operator=( + const any_io_executor& e) ASIO_NOEXCEPT; #if defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) /// Move assignment operator. - any_io_executor& operator=(any_io_executor&& e) ASIO_NOEXCEPT - { - base_type::operator=(static_cast(e)); - return *this; - } + ASIO_DECL any_io_executor& operator=( + any_io_executor&& e) ASIO_NOEXCEPT; #endif // defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) /// Assignment operator that sets the polymorphic wrapper to the empty state. - any_io_executor& operator=(nullptr_t) - { - base_type::operator=(nullptr_t()); - return *this; - } + ASIO_DECL any_io_executor& operator=(nullptr_t); /// Destructor. - ~any_io_executor() - { - } + ASIO_DECL ~any_io_executor(); /// Swap targets with another polymorphic wrapper. - void swap(any_io_executor& other) ASIO_NOEXCEPT - { - static_cast(*this).swap(static_cast(other)); - } + ASIO_DECL void swap(any_io_executor& other) ASIO_NOEXCEPT; /// Obtain a polymorphic wrapper with the specified property. /** @@ -230,6 +259,30 @@ class any_io_executor : #if !defined(GENERATING_DOCUMENTATION) +template <> +ASIO_DECL any_io_executor any_io_executor::require( + const execution::blocking_t::never_t&, int) const; + +template <> +ASIO_DECL any_io_executor any_io_executor::prefer( + const execution::blocking_t::possibly_t&, int) const; + +template <> +ASIO_DECL any_io_executor any_io_executor::prefer( + const execution::outstanding_work_t::tracked_t&, int) const; + +template <> +ASIO_DECL any_io_executor any_io_executor::prefer( + const execution::outstanding_work_t::untracked_t&, int) const; + +template <> +ASIO_DECL any_io_executor any_io_executor::prefer( + const execution::relationship_t::fork_t&, int) const; + +template <> +ASIO_DECL any_io_executor any_io_executor::prefer( + const execution::relationship_t::continuation_t&, int) const; + namespace traits { #if !defined(ASIO_HAS_DEDUCED_EQUALITY_COMPARABLE_TRAIT) @@ -297,4 +350,10 @@ struct prefer_member : #include "asio/detail/pop_options.hpp" +#if defined(ASIO_HEADER_ONLY) \ + && !defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) +# include "asio/impl/any_io_executor.ipp" +#endif // defined(ASIO_HEADER_ONLY) + // && !defined(ASIO_USE_TS_EXECUTOR_AS_DEFAULT) + #endif // ASIO_ANY_IO_EXECUTOR_HPP diff --git a/external_libraries/asio/include/asio/append.hpp b/external_libraries/asio/include/asio/append.hpp new file mode 100644 index 00000000..9ac4a950 --- /dev/null +++ b/external_libraries/asio/include/asio/append.hpp @@ -0,0 +1,78 @@ +// +// append.hpp +// ~~~~~~~~~~ +// +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// +// Distributed under the Boost Software License, Version 1.0. (See accompanying +// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +// + +#ifndef ASIO_APPEND_HPP +#define ASIO_APPEND_HPP + +#if defined(_MSC_VER) && (_MSC_VER >= 1200) +# pragma once +#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) + +#include "asio/detail/config.hpp" + +#if (defined(ASIO_HAS_STD_TUPLE) \ + && defined(ASIO_HAS_VARIADIC_TEMPLATES)) \ + || defined(GENERATING_DOCUMENTATION) + +#include +#include "asio/detail/type_traits.hpp" + +#include "asio/detail/push_options.hpp" + +namespace asio { + +/// Completion token type used to specify that the completion handler +/// arguments should be passed additional values after the results of the +/// operation. +template +class append_t +{ +public: + /// Constructor. + template + ASIO_CONSTEXPR explicit append_t( + ASIO_MOVE_ARG(T) completion_token, + ASIO_MOVE_ARG(V)... values) + : token_(ASIO_MOVE_CAST(T)(completion_token)), + values_(ASIO_MOVE_CAST(V)(values)...) + { + } + +//private: + CompletionToken token_; + std::tuple values_; +}; + +/// Completion token type used to specify that the completion handler +/// arguments should be passed additional values after the results of the +/// operation. +template +ASIO_NODISCARD inline ASIO_CONSTEXPR append_t< + typename decay::type, typename decay::type...> +append(ASIO_MOVE_ARG(CompletionToken) completion_token, + ASIO_MOVE_ARG(Values)... values) +{ + return append_t< + typename decay::type, typename decay::type...>( + ASIO_MOVE_CAST(CompletionToken)(completion_token), + ASIO_MOVE_CAST(Values)(values)...); +} + +} // namespace asio + +#include "asio/detail/pop_options.hpp" + +#include "asio/impl/append.hpp" + +#endif // (defined(ASIO_HAS_STD_TUPLE) + // && defined(ASIO_HAS_VARIADIC_TEMPLATES)) + // || defined(GENERATING_DOCUMENTATION) + +#endif // ASIO_APPEND_HPP diff --git a/external_libraries/asio/include/asio/as_tuple.hpp b/external_libraries/asio/include/asio/as_tuple.hpp new file mode 100644 index 00000000..96ac47c8 --- /dev/null +++ b/external_libraries/asio/include/asio/as_tuple.hpp @@ -0,0 +1,139 @@ +// +// as_tuple.hpp +// ~~~~~~~~~~~~ +// +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// +// Distributed under the Boost Software License, Version 1.0. (See accompanying +// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +// + +#ifndef ASIO_AS_TUPLE_HPP +#define ASIO_AS_TUPLE_HPP + +#if defined(_MSC_VER) && (_MSC_VER >= 1200) +# pragma once +#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) + +#include "asio/detail/config.hpp" + +#if (defined(ASIO_HAS_STD_TUPLE) \ + && defined(ASIO_HAS_VARIADIC_TEMPLATES)) \ + || defined(GENERATING_DOCUMENTATION) + +#include "asio/detail/type_traits.hpp" + +#include "asio/detail/push_options.hpp" + +namespace asio { + +/// A @ref completion_token adapter used to specify that the completion handler +/// arguments should be combined into a single tuple argument. +/** + * The as_tuple_t class is used to indicate that any arguments to the + * completion handler should be combined and passed as a single tuple argument. + * The arguments are first moved into a @c std::tuple and that tuple is then + * passed to the completion handler. + */ +template +class as_tuple_t +{ +public: + /// Tag type used to prevent the "default" constructor from being used for + /// conversions. + struct default_constructor_tag {}; + + /// Default constructor. + /** + * This constructor is only valid if the underlying completion token is + * default constructible and move constructible. The underlying completion + * token is itself defaulted as an argument to allow it to capture a source + * location. + */ + ASIO_CONSTEXPR as_tuple_t( + default_constructor_tag = default_constructor_tag(), + CompletionToken token = CompletionToken()) + : token_(ASIO_MOVE_CAST(CompletionToken)(token)) + { + } + + /// Constructor. + template + ASIO_CONSTEXPR explicit as_tuple_t( + ASIO_MOVE_ARG(T) completion_token) + : token_(ASIO_MOVE_CAST(T)(completion_token)) + { + } + + /// Adapts an executor to add the @c as_tuple_t completion token as the + /// default. + template + struct executor_with_default : InnerExecutor + { + /// Specify @c as_tuple_t as the default completion token type. + typedef as_tuple_t default_completion_token_type; + + /// Construct the adapted executor from the inner executor type. + template + executor_with_default(const InnerExecutor1& ex, + typename constraint< + conditional< + !is_same::value, + is_convertible, + false_type + >::type::value + >::type = 0) ASIO_NOEXCEPT + : InnerExecutor(ex) + { + } + }; + + /// Type alias to adapt an I/O object to use @c as_tuple_t as its + /// default completion token type. +#if defined(ASIO_HAS_ALIAS_TEMPLATES) \ + || defined(GENERATING_DOCUMENTATION) + template + using as_default_on_t = typename T::template rebind_executor< + executor_with_default >::other; +#endif // defined(ASIO_HAS_ALIAS_TEMPLATES) + // || defined(GENERATING_DOCUMENTATION) + + /// Function helper to adapt an I/O object to use @c as_tuple_t as its + /// default completion token type. + template + static typename decay::type::template rebind_executor< + executor_with_default::type::executor_type> + >::other + as_default_on(ASIO_MOVE_ARG(T) object) + { + return typename decay::type::template rebind_executor< + executor_with_default::type::executor_type> + >::other(ASIO_MOVE_CAST(T)(object)); + } + +//private: + CompletionToken token_; +}; + +/// Adapt a @ref completion_token to specify that the completion handler +/// arguments should be combined into a single tuple argument. +template +ASIO_NODISCARD inline +ASIO_CONSTEXPR as_tuple_t::type> +as_tuple(ASIO_MOVE_ARG(CompletionToken) completion_token) +{ + return as_tuple_t::type>( + ASIO_MOVE_CAST(CompletionToken)(completion_token)); +} + +} // namespace asio + +#include "asio/detail/pop_options.hpp" + +#include "asio/impl/as_tuple.hpp" + +#endif // (defined(ASIO_HAS_STD_TUPLE) + // && defined(ASIO_HAS_VARIADIC_TEMPLATES)) + // || defined(GENERATING_DOCUMENTATION) + +#endif // ASIO_AS_TUPLE_HPP diff --git a/external_libraries/asio/include/asio/associated_allocator.hpp b/external_libraries/asio/include/asio/associated_allocator.hpp index 3f945834..8e864673 100644 --- a/external_libraries/asio/include/asio/associated_allocator.hpp +++ b/external_libraries/asio/include/asio/associated_allocator.hpp @@ -2,7 +2,7 @@ // associated_allocator.hpp // ~~~~~~~~~~~~~~~~~~~~~~~~ // -// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -37,42 +37,58 @@ struct has_allocator_type : false_type template struct has_allocator_type::type> + typename void_type::type> : true_type { }; -template +template struct associated_allocator_impl { - typedef E type; + typedef void asio_associated_allocator_is_unspecialised; + + typedef A type; + + static type get(const T&) ASIO_NOEXCEPT + { + return type(); + } - static type get(const T&, const E& e) ASIO_NOEXCEPT + static const type& get(const T&, const A& a) ASIO_NOEXCEPT { - return e; + return a; } }; -template -struct associated_allocator_impl +struct associated_allocator_impl::type> { typedef typename T::allocator_type type; - static type get(const T& t, const E&) ASIO_NOEXCEPT + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get( + const T& t) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX((t.get_allocator())) + { + return t.get_allocator(); + } + + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get( + const T& t, const A&) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX((t.get_allocator())) { return t.get_allocator(); } }; -template -struct associated_allocator_impl +struct associated_allocator_impl::value >::type, typename void_type< - typename associator::type - >::type> : associator + typename associator::type + >::type> : associator { }; @@ -92,29 +108,32 @@ struct associated_allocator_impl > struct associated_allocator +#if !defined(GENERATING_DOCUMENTATION) + : detail::associated_allocator_impl +#endif // !defined(GENERATING_DOCUMENTATION) { +#if defined(GENERATING_DOCUMENTATION) /// If @c T has a nested type @c allocator_type, T::allocator_type. /// Otherwise @c Allocator. -#if defined(GENERATING_DOCUMENTATION) typedef see_below type; -#else // defined(GENERATING_DOCUMENTATION) - typedef typename detail::associated_allocator_impl::type type; -#endif // defined(GENERATING_DOCUMENTATION) + + /// If @c T has a nested type @c allocator_type, returns + /// t.get_allocator(). Otherwise returns @c type(). + static decltype(auto) get(const T& t) ASIO_NOEXCEPT; /// If @c T has a nested type @c allocator_type, returns /// t.get_allocator(). Otherwise returns @c a. - static type get(const T& t, - const Allocator& a = Allocator()) ASIO_NOEXCEPT - { - return detail::associated_allocator_impl::get(t, a); - } + static decltype(auto) get(const T& t, const Allocator& a) ASIO_NOEXCEPT; +#endif // defined(GENERATING_DOCUMENTATION) }; /// Helper function to obtain an object's associated allocator. @@ -122,7 +141,7 @@ struct associated_allocator * @returns associated_allocator::get(t) */ template -inline typename associated_allocator::type +ASIO_NODISCARD inline typename associated_allocator::type get_associated_allocator(const T& t) ASIO_NOEXCEPT { return associated_allocator::get(t); @@ -133,8 +152,11 @@ get_associated_allocator(const T& t) ASIO_NOEXCEPT * @returns associated_allocator::get(t, a) */ template -inline typename associated_allocator::type +ASIO_NODISCARD inline ASIO_AUTO_RETURN_TYPE_PREFIX2( + typename associated_allocator::type) get_associated_allocator(const T& t, const Allocator& a) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_allocator::get(t, a))) { return associated_allocator::get(t, a); } @@ -147,12 +169,37 @@ using associated_allocator_t #endif // defined(ASIO_HAS_ALIAS_TEMPLATES) +namespace detail { + +template +struct associated_allocator_forwarding_base +{ +}; + +template +struct associated_allocator_forwarding_base::asio_associated_allocator_is_unspecialised, + void + >::value + >::type> +{ + typedef void asio_associated_allocator_is_unspecialised; +}; + +} // namespace detail + #if defined(ASIO_HAS_STD_REFERENCE_WRAPPER) \ || defined(GENERATING_DOCUMENTATION) /// Specialisation of associated_allocator for @c std::reference_wrapper. template struct associated_allocator, Allocator> +#if !defined(GENERATING_DOCUMENTATION) + : detail::associated_allocator_forwarding_base +#endif // !defined(GENERATING_DOCUMENTATION) { /// Forwards @c type to the associator specialisation for the unwrapped type /// @c T. @@ -160,8 +207,17 @@ struct associated_allocator, Allocator> /// Forwards the request to get the allocator to the associator specialisation /// for the unwrapped type @c T. - static type get(reference_wrapper t, - const Allocator& a = Allocator()) ASIO_NOEXCEPT + static type get(reference_wrapper t) ASIO_NOEXCEPT + { + return associated_allocator::get(t.get()); + } + + /// Forwards the request to get the allocator to the associator specialisation + /// for the unwrapped type @c T. + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get( + reference_wrapper t, const Allocator& a) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_allocator::get(t.get(), a))) { return associated_allocator::get(t.get(), a); } diff --git a/external_libraries/asio/include/asio/associated_cancellation_slot.hpp b/external_libraries/asio/include/asio/associated_cancellation_slot.hpp index 6a809e71..65d82b64 100644 --- a/external_libraries/asio/include/asio/associated_cancellation_slot.hpp +++ b/external_libraries/asio/include/asio/associated_cancellation_slot.hpp @@ -2,7 +2,7 @@ // associated_cancellation_slot.hpp // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // -// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -18,6 +18,7 @@ #include "asio/detail/config.hpp" #include "asio/associator.hpp" #include "asio/cancellation_signal.hpp" +#include "asio/detail/functional.hpp" #include "asio/detail/type_traits.hpp" #include "asio/detail/push_options.hpp" @@ -48,7 +49,12 @@ struct associated_cancellation_slot_impl typedef S type; - static type get(const T&, const S& s = S()) ASIO_NOEXCEPT + static type get(const T&) ASIO_NOEXCEPT + { + return type(); + } + + static const type& get(const T&, const S& s) ASIO_NOEXCEPT { return s; } @@ -60,7 +66,16 @@ struct associated_cancellation_slot_impl struct associated_cancellation_slot @@ -110,10 +127,14 @@ struct associated_cancellation_slot /// @c CancellationSlot. typedef see_below type; + /// If @c T has a nested type @c cancellation_slot_type, returns + /// t.get_cancellation_slot(). Otherwise returns @c type(). + static decltype(auto) get(const T& t) ASIO_NOEXCEPT; + /// If @c T has a nested type @c cancellation_slot_type, returns /// t.get_cancellation_slot(). Otherwise returns @c s. - static type get(const T& t, - const CancellationSlot& s = CancellationSlot()) ASIO_NOEXCEPT; + static decltype(auto) get(const T& t, + const CancellationSlot& s) ASIO_NOEXCEPT; #endif // defined(GENERATING_DOCUMENTATION) }; @@ -122,7 +143,7 @@ struct associated_cancellation_slot * @returns associated_cancellation_slot::get(t) */ template -inline typename associated_cancellation_slot::type +ASIO_NODISCARD inline typename associated_cancellation_slot::type get_associated_cancellation_slot(const T& t) ASIO_NOEXCEPT { return associated_cancellation_slot::get(t); @@ -134,9 +155,12 @@ get_associated_cancellation_slot(const T& t) ASIO_NOEXCEPT * CancellationSlot>::get(t, st) */ template -inline typename associated_cancellation_slot::type +ASIO_NODISCARD inline ASIO_AUTO_RETURN_TYPE_PREFIX2( + typename associated_cancellation_slot::type) get_associated_cancellation_slot(const T& t, const CancellationSlot& st) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_cancellation_slot::get(t, st))) { return associated_cancellation_slot::get(t, st); } @@ -170,6 +194,43 @@ struct associated_cancellation_slot_forwarding_base +struct associated_cancellation_slot, CancellationSlot> +#if !defined(GENERATING_DOCUMENTATION) + : detail::associated_cancellation_slot_forwarding_base +#endif // !defined(GENERATING_DOCUMENTATION) +{ + /// Forwards @c type to the associator specialisation for the unwrapped type + /// @c T. + typedef typename associated_cancellation_slot::type type; + + /// Forwards the request to get the cancellation slot to the associator + /// specialisation for the unwrapped type @c T. + static type get(reference_wrapper t) ASIO_NOEXCEPT + { + return associated_cancellation_slot::get(t.get()); + } + + /// Forwards the request to get the cancellation slot to the associator + /// specialisation for the unwrapped type @c T. + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get(reference_wrapper t, + const CancellationSlot& s) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_cancellation_slot::get(t.get(), s))) + { + return associated_cancellation_slot::get(t.get(), s); + } +}; + +#endif // defined(ASIO_HAS_STD_REFERENCE_WRAPPER) + // || defined(GENERATING_DOCUMENTATION) + } // namespace asio #include "asio/detail/pop_options.hpp" diff --git a/external_libraries/asio/include/asio/associated_executor.hpp b/external_libraries/asio/include/asio/associated_executor.hpp index 1e62e37a..92279891 100644 --- a/external_libraries/asio/include/asio/associated_executor.hpp +++ b/external_libraries/asio/include/asio/associated_executor.hpp @@ -2,7 +2,7 @@ // associated_executor.hpp // ~~~~~~~~~~~~~~~~~~~~~~~ // -// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -51,7 +51,12 @@ struct associated_executor_impl typedef E type; - static type get(const T&, const E& e = E()) ASIO_NOEXCEPT + static type get(const T&) ASIO_NOEXCEPT + { + return type(); + } + + static const type& get(const T&, const E& e) ASIO_NOEXCEPT { return e; } @@ -63,7 +68,16 @@ struct associated_executor_impl struct associated_executor @@ -112,10 +128,13 @@ struct associated_executor /// Otherwise @c Executor. typedef see_below type; + /// If @c T has a nested type @c executor_type, returns + /// t.get_executor(). Otherwise returns @c type(). + static decltype(auto) get(const T& t) ASIO_NOEXCEPT; + /// If @c T has a nested type @c executor_type, returns /// t.get_executor(). Otherwise returns @c ex. - static type get(const T& t, - const Executor& ex = Executor()) ASIO_NOEXCEPT; + static decltype(auto) get(const T& t, const Executor& ex) ASIO_NOEXCEPT; #endif // defined(GENERATING_DOCUMENTATION) }; @@ -124,7 +143,7 @@ struct associated_executor * @returns associated_executor::get(t) */ template -inline typename associated_executor::type +ASIO_NODISCARD inline typename associated_executor::type get_associated_executor(const T& t) ASIO_NOEXCEPT { return associated_executor::get(t); @@ -135,11 +154,14 @@ get_associated_executor(const T& t) ASIO_NOEXCEPT * @returns associated_executor::get(t, ex) */ template -inline typename associated_executor::type +ASIO_NODISCARD inline ASIO_AUTO_RETURN_TYPE_PREFIX2( + typename associated_executor::type) get_associated_executor(const T& t, const Executor& ex, typename constraint< is_executor::value || execution::is_executor::value >::type = 0) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_executor::get(t, ex))) { return associated_executor::get(t, ex); } @@ -150,8 +172,8 @@ get_associated_executor(const T& t, const Executor& ex, * ExecutionContext::executor_type>::get(t, ctx.get_executor()) */ template -inline typename associated_executor::type +ASIO_NODISCARD inline typename associated_executor::type get_associated_executor(const T& t, ExecutionContext& ctx, typename constraint::value>::type = 0) ASIO_NOEXCEPT @@ -205,8 +227,17 @@ struct associated_executor, Executor> /// Forwards the request to get the executor to the associator specialisation /// for the unwrapped type @c T. - static type get(reference_wrapper t, - const Executor& ex = Executor()) ASIO_NOEXCEPT + static type get(reference_wrapper t) ASIO_NOEXCEPT + { + return associated_executor::get(t.get()); + } + + /// Forwards the request to get the executor to the associator specialisation + /// for the unwrapped type @c T. + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get( + reference_wrapper t, const Executor& ex) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_executor::get(t.get(), ex))) { return associated_executor::get(t.get(), ex); } diff --git a/external_libraries/asio/include/asio/associated_immediate_executor.hpp b/external_libraries/asio/include/asio/associated_immediate_executor.hpp new file mode 100644 index 00000000..54bced17 --- /dev/null +++ b/external_libraries/asio/include/asio/associated_immediate_executor.hpp @@ -0,0 +1,297 @@ +// +// associated_immediate_executor.hpp +// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +// +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// +// Distributed under the Boost Software License, Version 1.0. (See accompanying +// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +// + +#ifndef ASIO_ASSOCIATED_IMMEDIATE_EXECUTOR_HPP +#define ASIO_ASSOCIATED_IMMEDIATE_EXECUTOR_HPP + +#if defined(_MSC_VER) && (_MSC_VER >= 1200) +# pragma once +#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) + +#include "asio/detail/config.hpp" +#include "asio/associator.hpp" +#include "asio/detail/functional.hpp" +#include "asio/detail/type_traits.hpp" +#include "asio/execution/blocking.hpp" +#include "asio/execution/executor.hpp" +#include "asio/execution_context.hpp" +#include "asio/is_executor.hpp" +#include "asio/require.hpp" + +#include "asio/detail/push_options.hpp" + +namespace asio { + +template +struct associated_immediate_executor; + +namespace detail { + +template +struct has_immediate_executor_type : false_type +{ +}; + +template +struct has_immediate_executor_type::type> + : true_type +{ +}; + +template +struct default_immediate_executor +{ + typedef typename require_result::type type; + + static type get(const E& e) ASIO_NOEXCEPT + { + return asio::require(e, execution::blocking.never); + } +}; + +template +struct default_immediate_executor::value + >::type, + typename enable_if< + is_executor::value + >::type> +{ + class type : public E + { + public: + template + explicit type(const Executor1& e, + typename constraint< + conditional< + !is_same::value, + is_convertible, + false_type + >::type::value + >::type = 0) ASIO_NOEXCEPT + : E(e) + { + } + + type(const type& other) ASIO_NOEXCEPT + : E(static_cast(other)) + { + } + +#if defined(ASIO_HAS_MOVE) + type(type&& other) ASIO_NOEXCEPT + : E(ASIO_MOVE_CAST(E)(other)) + { + } +#endif // defined(ASIO_HAS_MOVE) + + template + void dispatch(ASIO_MOVE_ARG(Function) f, const Allocator& a) const + { + this->post(ASIO_MOVE_CAST(Function)(f), a); + } + + friend bool operator==(const type& a, const type& b) ASIO_NOEXCEPT + { + return static_cast(a) == static_cast(b); + } + + friend bool operator!=(const type& a, const type& b) ASIO_NOEXCEPT + { + return static_cast(a) != static_cast(b); + } + }; + + static type get(const E& e) ASIO_NOEXCEPT + { + return type(e); + } +}; + +template +struct associated_immediate_executor_impl +{ + typedef void asio_associated_immediate_executor_is_unspecialised; + + typedef typename default_immediate_executor::type type; + + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get( + const T&, const E& e) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX((default_immediate_executor::get(e))) + { + return default_immediate_executor::get(e); + } +}; + +template +struct associated_immediate_executor_impl::type> +{ + typedef typename T::immediate_executor_type type; + + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get( + const T& t, const E&) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX((t.get_immediate_executor())) + { + return t.get_immediate_executor(); + } +}; + +template +struct associated_immediate_executor_impl::value + >::type, + typename void_type< + typename associator::type + >::type> : associator +{ +}; + +} // namespace detail + +/// Traits type used to obtain the immediate executor associated with an object. +/** + * A program may specialise this traits type if the @c T template parameter in + * the specialisation is a user-defined type. The template parameter @c + * Executor shall be a type meeting the Executor requirements. + * + * Specialisations shall meet the following requirements, where @c t is a const + * reference to an object of type @c T, and @c e is an object of type @c + * Executor. + * + * @li Provide a nested typedef @c type that identifies a type meeting the + * Executor requirements. + * + * @li Provide a noexcept static member function named @c get, callable as @c + * get(t) and with return type @c type or a (possibly const) reference to @c + * type. + * + * @li Provide a noexcept static member function named @c get, callable as @c + * get(t,e) and with return type @c type or a (possibly const) reference to @c + * type. + */ +template +struct associated_immediate_executor +#if !defined(GENERATING_DOCUMENTATION) + : detail::associated_immediate_executor_impl +#endif // !defined(GENERATING_DOCUMENTATION) +{ +#if defined(GENERATING_DOCUMENTATION) + /// If @c T has a nested type @c immediate_executor_type, + // T::immediate_executor_type. Otherwise @c Executor. + typedef see_below type; + + /// If @c T has a nested type @c immediate_executor_type, returns + /// t.get_immediate_executor(). Otherwise returns + /// asio::require(ex, asio::execution::blocking.never). + static decltype(auto) get(const T& t, const Executor& ex) ASIO_NOEXCEPT; +#endif // defined(GENERATING_DOCUMENTATION) +}; + +/// Helper function to obtain an object's associated executor. +/** + * @returns associated_immediate_executor::get(t, ex) + */ +template +ASIO_NODISCARD inline ASIO_AUTO_RETURN_TYPE_PREFIX2( + typename associated_immediate_executor::type) +get_associated_immediate_executor(const T& t, const Executor& ex, + typename constraint< + is_executor::value || execution::is_executor::value + >::type = 0) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_immediate_executor::get(t, ex))) +{ + return associated_immediate_executor::get(t, ex); +} + +/// Helper function to obtain an object's associated executor. +/** + * @returns associated_immediate_executor::get(t, ctx.get_executor()) + */ +template +ASIO_NODISCARD inline typename associated_immediate_executor::type +get_associated_immediate_executor(const T& t, ExecutionContext& ctx, + typename constraint::value>::type = 0) ASIO_NOEXCEPT +{ + return associated_immediate_executor::get(t, ctx.get_executor()); +} + +#if defined(ASIO_HAS_ALIAS_TEMPLATES) + +template +using associated_immediate_executor_t = + typename associated_immediate_executor::type; + +#endif // defined(ASIO_HAS_ALIAS_TEMPLATES) + +namespace detail { + +template +struct associated_immediate_executor_forwarding_base +{ +}; + +template +struct associated_immediate_executor_forwarding_base::asio_associated_immediate_executor_is_unspecialised, + void + >::value + >::type> +{ + typedef void asio_associated_immediate_executor_is_unspecialised; +}; + +} // namespace detail + +#if defined(ASIO_HAS_STD_REFERENCE_WRAPPER) \ + || defined(GENERATING_DOCUMENTATION) + +/// Specialisation of associated_immediate_executor for +/// @c std::reference_wrapper. +template +struct associated_immediate_executor, Executor> +#if !defined(GENERATING_DOCUMENTATION) + : detail::associated_immediate_executor_forwarding_base +#endif // !defined(GENERATING_DOCUMENTATION) +{ + /// Forwards @c type to the associator specialisation for the unwrapped type + /// @c T. + typedef typename associated_immediate_executor::type type; + + /// Forwards the request to get the executor to the associator specialisation + /// for the unwrapped type @c T. + static ASIO_AUTO_RETURN_TYPE_PREFIX(type) get( + reference_wrapper t, const Executor& ex) ASIO_NOEXCEPT + ASIO_AUTO_RETURN_TYPE_SUFFIX(( + associated_immediate_executor::get(t.get(), ex))) + { + return associated_immediate_executor::get(t.get(), ex); + } +}; + +#endif // defined(ASIO_HAS_STD_REFERENCE_WRAPPER) + // || defined(GENERATING_DOCUMENTATION) + +} // namespace asio + +#include "asio/detail/pop_options.hpp" + +#endif // ASIO_ASSOCIATED_IMMEDIATE_EXECUTOR_HPP diff --git a/external_libraries/asio/include/asio/associator.hpp b/external_libraries/asio/include/asio/associator.hpp index 0f93b120..e954c442 100644 --- a/external_libraries/asio/include/asio/associator.hpp +++ b/external_libraries/asio/include/asio/associator.hpp @@ -2,7 +2,7 @@ // associator.hpp // ~~~~~~~~~~~~~~ // -// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) diff --git a/external_libraries/asio/include/asio/async_result.hpp b/external_libraries/asio/include/asio/async_result.hpp index 1750e19e..a7f97b0a 100644 --- a/external_libraries/asio/include/asio/async_result.hpp +++ b/external_libraries/asio/include/asio/async_result.hpp @@ -2,7 +2,7 @@ // async_result.hpp // ~~~~~~~~~~~~~~~~ // -// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com) +// Copyright (c) 2003-2023 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -311,6 +311,12 @@ struct are_simple_completion_signatures { }; +template <> +struct simple_completion_signature +{ + typedef void type; +}; + template struct simple_completion_signature { @@ -801,6 +807,40 @@ struct async_result_has_initiate_memfn ASIO_INITFN_RESULT_TYPE3(ct, sig0, sig1, sig2) #endif +#if defined(GENERATING_DOCUMENTATION) +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX(ct, sig) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX2(ct, sig0, sig1) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX3(ct, sig0, sig1, sig2) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_SUFFIX(expr) +#elif defined(ASIO_HAS_RETURN_TYPE_DEDUCTION) +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX(ct, sig) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX2(ct, sig0, sig1) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX3(ct, sig0, sig1, sig2) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_SUFFIX(expr) +#elif defined(ASIO_HAS_DECLTYPE) +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX(ct, sig) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX2(ct, sig0, sig1) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX3(ct, sig0, sig1, sig2) \ + auto +# define ASIO_INITFN_AUTO_RESULT_TYPE_SUFFIX(expr) -> decltype expr +#else +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX(ct, sig) \ + ASIO_INITFN_RESULT_TYPE(ct, sig) +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX2(ct, sig0, sig1) \ + ASIO_INITFN_RESULT_TYPE2(ct, sig0, sig1) +# define ASIO_INITFN_AUTO_RESULT_TYPE_PREFIX3(ct, sig0, sig1, sig2) \ + ASIO_INITFN_RESULT_TYPE3(ct, sig0, sig1, sig2) +# define ASIO_INITFN_AUTO_RESULT_TYPE_SUFFIX(expr) +#endif + #if defined(GENERATING_DOCUMENTATION) # define ASIO_INITFN_DEDUCED_RESULT_TYPE(ct, sig, expr) \ void_or_deduced @@ -1195,6 +1235,372 @@ ASIO_CONCEPT completion_token_for = namespace detail { +struct async_operation_probe {}; +struct async_operation_probe_result {}; + +template +struct is_async_operation_call : false_type +{ +}; + +template +struct is_async_operation_call::type, + async_operation_probe_result + >::value + >::type + >::type> : true_type +{ +}; + +} // namespace detail + +#if !defined(GENERATING_DOCUMENTATION) +#if defined(ASIO_HAS_VARIADIC_TEMPLATES) + +template +class async_result +{ +public: + typedef detail::async_operation_probe_result return_type; + + template + static return_type initiate(ASIO_MOVE_ARG(Initiation), + detail::async_operation_probe, ASIO_MOVE_ARG(InitArgs)...) + { + return return_type(); + } +}; + +#else // defined(ASIO_HAS_VARIADIC_TEMPLATES) + +namespace detail { + +struct async_result_probe_base +{ + typedef detail::async_operation_probe_result return_type; + + template + static return_type initiate(ASIO_MOVE_ARG(Initiation), + detail::async_operation_probe) + { + return return_type(); + } + +#define ASIO_PRIVATE_INITIATE_DEF(n) \ + template \ + static return_type initiate(ASIO_MOVE_ARG(Initiation), \ + detail::async_operation_probe, \ + ASIO_VARIADIC_UNNAMED_MOVE_PARAMS(n)) \ + { \ + return return_type(); \ + } \ + /**/ + ASIO_VARIADIC_GENERATE(ASIO_PRIVATE_INITIATE_DEF) +#undef ASIO_PRIVATE_INITIATE_DEF +}; + +} // namespace detail + +template +class async_result + : public detail::async_result_probe_base {}; + +template +class async_result + : public detail::async_result_probe_base {}; + +template +class async_result + : public detail::async_result_probe_base {}; + +#endif // defined(ASIO_HAS_VARIADIC_TEMPLATES) +#endif // !defined(GENERATING_DOCUMENTATION) + +#if defined(GENERATING_DOCUMENTATION) + +/// The is_async_operation trait detects whether a type @c T and arguments +/// @c Args... may be used to initiate an asynchronous operation. +/** + * Class template @c is_async_operation is a trait is derived from @c true_type + * if the expression T(Args..., token) initiates an asynchronous + * operation, where @c token is an unspecified completion token type. Otherwise, + * @c is_async_operation is derived from @c false_type. + */ +template +struct is_async_operation : integral_constant +{ +}; + +#elif defined(ASIO_HAS_VARIADIC_TEMPLATES) + +template +struct is_async_operation : + detail::is_async_operation_call< + T(Args..., detail::async_operation_probe)> +{ +}; + +#else // defined(ASIO_HAS_VARIADIC_TEMPLATES) + +template +struct is_async_operation; + +template +struct is_async_operation : + detail::is_async_operation_call< + T(detail::async_operation_probe)> +{ +}; + +#define ASIO_PRIVATE_IS_ASYNC_OP_DEF(n) \ + template \ + struct is_async_operation : \ + detail::is_async_operation_call< \ + T(ASIO_VARIADIC_TARGS(n), detail::async_operation_probe)> \ + { \ + }; \ + /**/ + ASIO_VARIADIC_GENERATE(ASIO_PRIVATE_IS_ASYNC_OP_DEF) +#undef ASIO_PRIVATE_IS_ASYNC_OP_DEF + +#endif // defined(ASIO_HAS_VARIADIC_TEMPLATES) + +#if defined(ASIO_HAS_CONCEPTS) \ + && defined(ASIO_HAS_VARIADIC_TEMPLATES) + +template +ASIO_CONCEPT async_operation = is_async_operation::value; + +#define ASIO_ASYNC_OPERATION(t) \ + ::asio::async_operation +#define ASIO_ASYNC_OPERATION1(t, a0) \ + ::asio::async_operation +#define ASIO_ASYNC_OPERATION2(t, a0, a1) \ + ::asio::async_operation +#define ASIO_ASYNC_OPERATION3(t, a0, a1, a2) \ + ::asio::async_operation + +#else // defined(ASIO_HAS_CONCEPTS) + // && defined(ASIO_HAS_VARIADIC_TEMPLATES) + +#define ASIO_ASYNC_OPERATION(t) typename +#define ASIO_ASYNC_OPERATION1(t, a0) typename +#define ASIO_ASYNC_OPERATION2(t, a0, a1) typename +#define ASIO_ASYNC_OPERATION3(t, a0, a1, a2) typename + +#endif // defined(ASIO_HAS_CONCEPTS) + // && defined(ASIO_HAS_VARIADIC_TEMPLATES) + +namespace detail { + +struct completion_signature_probe {}; + +#if defined(ASIO_HAS_VARIADIC_TEMPLATES) + +template +struct completion_signature_probe_result +{ + template