Skip to content

Commit

Permalink
Update conan and fix #392 (#393)
Browse files Browse the repository at this point in the history
* Fix #363

* Prepare 1.6.2 release

* Update status badge and minor wording improvements

* issue 392: The coroutine operators should use the defined executor of the future
and not the default_executor

* Update conan version because of expired certificate

* Update to more recent conan version

* Update conan for Windows too
  • Loading branch information
FelixPetriconi authored Feb 11, 2022
1 parent c86c645 commit 89ea735
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .github/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ if [[ "$(uname -s)" == 'Darwin' ]]; then
fi

pip install --upgrade pip
pip install conan_package_tools==0.35.0
pip install conan==1.32.0
pip install conan_package_tools==0.37.0
pip install conan==1.43.0

conan --version
conan user
4 changes: 2 additions & 2 deletions .github/workflows/stlab.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ jobs:
python.exe --version
cmake --version
python.exe -m pip install --upgrade pip
pip.exe install conan_package_tools==0.35.0
pip.exe install conan==1.32.0
pip.exe install conan_package_tools==0.37.0
pip.exe install conan==1.43.0
conan --version
conan user
shell: cmd
Expand Down
2 changes: 1 addition & 1 deletion cmake/stlab/coroutines/MSVC.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ string( CONCAT activate
# If using MSVC and active, set the coroutines flag
#
target_compile_options( coroutines INTERFACE
$<$<AND:$<CXX_COMPILER_ID:MSVC>,${active}>:/await> )
$<$<AND:$<CXX_COMPILER_ID:MSVC>,${active}>:/await /permissive-> )

#
# If using MSVC and active, set a preprocessor definition to enable
Expand Down
2 changes: 1 addition & 1 deletion cmake/stlab/development/MSVC.cmake
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
set( stlab_MSVC_base_flags /W3 /WX /D_SILENCE_ALL_CXX17_DEPRECATION_WARNINGS)
set( stlab_MSVC_base_flags /W3 /WX /D_SILENCE_ALL_CXX17_DEPRECATION_WARNINGS /bigobj /Zc:__cplusplus)
set( stlab_MSVC_debug_flags )
set( stlab_MSVC_coverage_flags )
set( stlab_MSVC_release_flags )
Expand Down
5 changes: 2 additions & 3 deletions stlab/concurrency/future.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2005,8 +2005,7 @@ auto operator co_await(stlab::future<R> f) {

void await_suspend(std::experimental::coroutine_handle<> ch) {
std::move(_input)
.then(stlab::default_executor,
[this, ch](auto&& result) mutable {
.then([this, ch](auto&& result) mutable {
this->_result = std::forward<decltype(result)>(result);
ch.resume();
})
Expand All @@ -2026,7 +2025,7 @@ inline auto operator co_await(stlab::future<void> f) {

inline void await_suspend(std::experimental::coroutine_handle<> ch) {
std::move(_input)
.then(stlab::default_executor, [ch]() mutable { ch.resume(); })
.then([ch]() mutable { ch.resume(); })
.detach();
}
};
Expand Down

0 comments on commit 89ea735

Please sign in to comment.