Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed wrong configuration for ASIO_HAS_CO_AWAIT #1145

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 20 additions & 12 deletions asio/include/asio/detail/config.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2072,25 +2072,25 @@
// Support the co_await keyword on compilers known to allow it.
#if !defined(ASIO_HAS_CO_AWAIT)
# if !defined(ASIO_DISABLE_CO_AWAIT)
# if defined(ASIO_MSVC)
# if (_MSC_VER >= 1928) && (_MSVC_LANG >= 201705) && !defined(__clang__)
# if ((defined(__cpp_coroutines) && (__cpp_coroutines >= 201707L)) || (defined(__cpp_impl_coroutine) && (__cpp_impl_coroutine >= 201902L)))
# define ASIO_HAS_CO_AWAIT 1
# elif !defined(ASIO_HAS_CO_AWAIT) && defined(ASIO_MSVC)
# if (_MSC_VER >= 1928) && (_MSVC_LANG >= 201705)
# define ASIO_HAS_CO_AWAIT 1
# elif (_MSC_FULL_VER >= 190023506)
# if defined(_RESUMABLE_FUNCTIONS_SUPPORTED)
# define ASIO_HAS_CO_AWAIT 1
# endif // defined(_RESUMABLE_FUNCTIONS_SUPPORTED)
# endif // (_MSC_FULL_VER >= 190023506)
# elif defined(__clang__)
# endif // !defined(ASIO_HAS_CO_AWAIT) && defined(ASIO_MSVC)
# if !defined(ASIO_HAS_CO_AWAIT) && defined(__clang__)
# if (__cplusplus >= 201703) && (__cpp_coroutines >= 201703)
# if __has_include(<experimental/coroutine>)
# define ASIO_HAS_CO_AWAIT 1
# endif // __has_include(<experimental/coroutine>)
# define ASIO_HAS_CO_AWAIT 1
# endif // (__cplusplus >= 201703) && (__cpp_coroutines >= 201703)
# elif defined(__GNUC__)
# endif // !defined(ASIO_HAS_CO_AWAIT) && defined(__clang__)
# if !defined(ASIO_HAS_CO_AWAIT) && defined(__GNUC__)
# if (__cplusplus >= 201709) && (__cpp_impl_coroutine >= 201902)
# if __has_include(<coroutine>)
# define ASIO_HAS_CO_AWAIT 1
# endif // __has_include(<coroutine>)
# define ASIO_HAS_CO_AWAIT 1
# endif // (__cplusplus >= 201709) && (__cpp_impl_coroutine >= 201902)
# endif // defined(__GNUC__)
# endif // !defined(ASIO_DISABLE_CO_AWAIT)
Expand All @@ -2099,12 +2099,20 @@
// Standard library support for coroutines.
#if !defined(ASIO_HAS_STD_COROUTINE)
# if !defined(ASIO_DISABLE_STD_COROUTINE)
# if defined(ASIO_MSVC)
# if __has_include(<version>)
# include <version>
# elif __has_include(<coroutine>)
# include <coroutine>
# endif //__has_include(<coroutine>)
# if defined(__cpp_lib_coroutine) && (__cpp_lib_coroutine >= 201902)
# define ASIO_HAS_STD_COROUTINE 1
# endif // defined(__cpp_lib_coroutine) && (__cpp_lib_coroutine >= 201902)
# if !defined(ASIO_HAS_STD_COROUTINE) && defined(ASIO_MSVC)
# if (_MSC_VER >= 1928) && (_MSVC_LANG >= 201705)
# define ASIO_HAS_STD_COROUTINE 1
# endif // (_MSC_VER >= 1928) && (_MSVC_LANG >= 201705)
# endif // defined(ASIO_MSVC)
# if defined(__GNUC__)
# if !defined(ASIO_HAS_STD_COROUTINE) && defined(__GNUC__)
# if (__cplusplus >= 201709) && (__cpp_impl_coroutine >= 201902)
# if __has_include(<coroutine>)
# define ASIO_HAS_STD_COROUTINE 1
Expand Down