Boost logo

Boost :

From: Stefan Heinzmann (stefan_heinzmann_at_[hidden])
Date: 2021-11-13 15:47:40


Hi all,

I have taken the opportunity to migrate my code to use any_io_executor
instead of executor, as recommended here:

https://stackoverflow.com/questions/65840258/boost-1-74-0-asio-executor-migration-issues

I now don't need to define BOOST_ASIO_USE_TS_EXECUTOR_AS_DEFAULT
anymore. That fixes the problem. I verified this by compiling with
gcc-11, too, where the original problem was also present.

Hence it seems to me that backwards compatibility of boost::asio through
BOOST_ASIO_USE_TS_EXECUTOR_AS_DEFAULT is broken in 1.78.0.beta1.

Cheers
Stefan Heinzmann

Am 13/11/2021 um 14:28 schrieb Stefan Heinzmann:
> Hi all,
>
> I'm observing a problem with boost::asio that has surfaced with the
> newest beta relative to version 1.77.0, using MSVC 16.11.6.
>
> I'm getting the following errors:
>
> 1>...src\libs\asio\include\boost/asio/impl/any_io_executor.ipp(26,18):
> error C2039: 'any_io_executor': is not a member of 'boost::asio::executor'
> 1>...src\libs\asio\include\boost/asio/executor.hpp(48): message : see
> declaration of 'boost::asio::executor'
> 1>...src\libs\asio\include\boost/asio/impl/any_io_executor.ipp(26,34):
> error C2059: syntax error: ')'
> 1>...src\libs\asio\include\boost/asio/impl/any_io_executor.ipp(28,1):
> error C4430: missing type specifier - int assumed. Note: C++ does not
> support default-int
>
> ...and so on.
>
> The errors seem rather weird to me, so I might be doing something wrong
> myself, but the exact same code compiles fine with 1.77.0, using the
> same compiler.
>
> Has anyone got an idea what's wrong? Should I raise an issue in github?
>
> Cheers
> Stefan Heinzmann


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk