mirror of
https://github.com/Naios/continuable.git
synced 2025-12-06 16:56:44 +08:00
Also test MSVC with /std:c++latest
This commit is contained in:
parent
6e6297194e
commit
7189068037
@ -45,6 +45,10 @@ option(CTI_CONTINUABLE_WITH_EXPERIMENTAL_COROUTINE
|
|||||||
"Enable co_await support"
|
"Enable co_await support"
|
||||||
OFF)
|
OFF)
|
||||||
|
|
||||||
|
option(CTI_CONTINUABLE_WITH_CPP_LATEST
|
||||||
|
"Enable the highest C++ standard available for testing polyfills"
|
||||||
|
OFF)
|
||||||
|
|
||||||
include(cmake/CMakeLists.txt)
|
include(cmake/CMakeLists.txt)
|
||||||
|
|
||||||
set(THREADS_PREFER_PTHREAD_FLAG ON)
|
set(THREADS_PREFER_PTHREAD_FLAG ON)
|
||||||
|
|||||||
@ -4,7 +4,11 @@ image:
|
|||||||
environment:
|
environment:
|
||||||
matrix:
|
matrix:
|
||||||
- WITH_NO_EXCEPTIONS: OFF
|
- WITH_NO_EXCEPTIONS: OFF
|
||||||
|
WITH_CPP_LATEST: OFF
|
||||||
- WITH_NO_EXCEPTIONS: ON
|
- WITH_NO_EXCEPTIONS: ON
|
||||||
|
WITH_CPP_LATEST: OFF
|
||||||
|
- WITH_NO_EXCEPTIONS: OFF
|
||||||
|
WITH_CPP_LATEST: ON
|
||||||
|
|
||||||
configuration:
|
configuration:
|
||||||
- Debug
|
- Debug
|
||||||
@ -23,6 +27,7 @@ before_build:
|
|||||||
cmake -H. -Bbuild -A%PLATFORM%
|
cmake -H. -Bbuild -A%PLATFORM%
|
||||||
-DCTI_CONTINUABLE_WITH_NO_EXCEPTIONS=%WITH_NO_EXCEPTIONS%
|
-DCTI_CONTINUABLE_WITH_NO_EXCEPTIONS=%WITH_NO_EXCEPTIONS%
|
||||||
-DCTI_CONTINUABLE_WITH_EXPERIMENTAL_COROUTINE=ON
|
-DCTI_CONTINUABLE_WITH_EXPERIMENTAL_COROUTINE=ON
|
||||||
|
-DCTI_CONTINUABLE_WITH_CPP_LATEST=ON
|
||||||
|
|
||||||
build_script:
|
build_script:
|
||||||
- cmd: cmake --build build --config %CONFIGURATION% --target ALL_BUILD -- /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /verbosity:minimal /maxcpucount:2 /nologo
|
- cmd: cmake --build build --config %CONFIGURATION% --target ALL_BUILD -- /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /verbosity:minimal /maxcpucount:2 /nologo
|
||||||
|
|||||||
@ -41,6 +41,16 @@ target_compile_options(continuable-features-warnings
|
|||||||
INTERFACE
|
INTERFACE
|
||||||
/W4)
|
/W4)
|
||||||
|
|
||||||
|
if (CTI_CONTINUABLE_WITH_CPP_LATEST)
|
||||||
|
target_compile_options(continuable-features-flags
|
||||||
|
INTERFACE
|
||||||
|
/std:c++latest)
|
||||||
|
else()
|
||||||
|
target_compile_options(continuable-features-flags
|
||||||
|
INTERFACE
|
||||||
|
/std:c++14)
|
||||||
|
endif()
|
||||||
|
|
||||||
if (CTI_CONTINUABLE_WITH_NO_EXCEPTIONS)
|
if (CTI_CONTINUABLE_WITH_NO_EXCEPTIONS)
|
||||||
target_compile_definitions(continuable-features-noexcept
|
target_compile_definitions(continuable-features-noexcept
|
||||||
INTERFACE
|
INTERFACE
|
||||||
|
|||||||
@ -18,11 +18,10 @@ source_group(test FILES ${TEST})
|
|||||||
target_link_libraries(test-playground
|
target_link_libraries(test-playground
|
||||||
PRIVATE
|
PRIVATE
|
||||||
gtest
|
gtest
|
||||||
continuable)
|
continuable
|
||||||
|
continuable-features-flags
|
||||||
target_compile_definitions(test-playground
|
continuable-features-warnings
|
||||||
PUBLIC
|
continuable-features-noexcept)
|
||||||
-DCONTINUABLE_WITH_NO_EXCEPTIONS)
|
|
||||||
|
|
||||||
add_test(NAME continuable-playground-tests
|
add_test(NAME continuable-playground-tests
|
||||||
COMMAND test-playground)
|
COMMAND test-playground)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user