https://www.boost.org/doc/libs/1_87_0/d ... time3.html
- для async_write ()
Код: Выделить всё
main.cpp:47:9: No matching function for call to 'async_write' write.hpp:: candidate template ignored: constraints not satisfied [with AsyncWriteStream = tcp::socket, ConstBufferSequence = mutable_buffers_1, WriteToken = typename _Bind_helper::type] :564:5: note: because '::boost::asio::completion_token_for' evaluated to false async_result.hpp:1214:5: because 'async_initiate(detail::initiation_archetype{}, t)' would be invalid: no matching function for call to 'async_initiate' write.hpp:: candidate template ignored: substitution failure [with AsyncWriteStream = tcp::socket, DynamicBuffer_v1 = mutable_buffers_1, WriteToken = typename _Bind_helper::type]: no type named 'type' in 'boost::asio::constraint' write.hpp:: candidate template ignored: could not match 'boost::asio::basic_streambuf' against 'mutable_buffers_1' write.hpp:: candidate template ignored: substitution failure [with AsyncWriteStream = tcp::socket, DynamicBuffer_v2 = mutable_buffers_1, WriteToken = typename _Bind_helper::type]: no type named 'type' in 'boost::asio::constraint' write.hpp:: candidate function template not viable: requires 4 arguments, but 3 were provided write.hpp:: candidate function template not viable: requires at least 4 arguments, but 3 were provided write.hpp:: candidate function template not viable: requires at least 4 arguments, but 3 were provided write.hpp:: candidate function template not viable: requires at least 4 arguments, but 3 were provided - для async_accte ()
Код: Выделить всё
main.cpp:84:9: No matching member function for call to 'async_accept' basic_socket_acceptor.hpp:1531:3: candidate function template not viable: no known conversion from 'typename _Bind_helper::type' (aka '_Bind') to 'endpoint_type &' (aka 'basic_endpoint &') for 2nd argument basic_socket_acceptor.hpp:2500:3: candidate function template not viable: no known conversion from 'typename _Bind_helper::type' (aka '_Bind') to 'endpoint_type &' (aka 'basic_endpoint &') for 2nd argument basic_socket_acceptor.hpp:2603:3: candidate function template not viable: no known conversion from 'typename _Bind_helper::type' (aka '_Bind') to 'endpoint_type &' (aka 'basic_endpoint &') for 2nd argument basic_socket_acceptor.hpp:2211:3: candidate function template not viable: no known conversion from 'tcp::socket' (aka 'basic_stream_socket') to 'endpoint_type &' (aka 'basic_endpoint &') for 1st argument basic_socket_acceptor.hpp:1398:3: candidate template ignored: constraints not satisfied [with Protocol1 = boost::asio::ip::tcp, Executor1 = boost::asio::any_io_executor, AcceptToken = typename _Bind_helper::type] :1394:7: note: because '::boost::asio::completion_token_for' evaluated to false async_result.hpp:1214:5: because 'async_initiate(detail::initiation_archetype{}, t)' would be invalid: no matching function for call to 'async_initiate' basic_socket_acceptor.hpp:1936:3: candidate template ignored: substitution failure [with Executor1 = tcp::socket, MoveAcceptToken = typename _Bind_helper::type]: no type named 'type' in 'boost::asio::constraint' basic_socket_acceptor.hpp:2035:3: candidate template ignored: substitution failure [with ExecutionContext = tcp::socket, MoveAcceptToken = typename _Bind_helper::type]: no type named 'type' in 'boost::asio::constraint' basic_socket_acceptor.hpp:1679:3: candidate function template not viable: allows at most single argument 'token', but 2 arguments were provided
Подробнее здесь: https://stackoverflow.com/questions/793 ... -using-c23