boostorg / thread

Boost.org thread module
http://boost.org/libs/thread
199 stars 161 forks source link

Fixed lockable_traits bugs #240

Closed Kojoley closed 5 years ago

Kojoley commented 5 years ago

Traits does not handle noexcept qualifiers (which are part of function type in C++17) and wrongly did not detect methods. Because of this on MSVC 14.1 with -std=c++17 boost::is_mutex_type<boost::mutex>::value is false and boost::lock(mutex) does not compile.

Fixes #222.

Kojoley commented 5 years ago

Hm, there is no boost macro to detect P0012R1, I think that it would be better to switch to decltype based detection.

viboes commented 5 years ago

Hi, have you checked on Windows? I see yet a lot of issues on the appVeyor.

Kojoley commented 5 years ago

The PR has nothing with issues on the Appveyor which are transient. You can try to solve them by adjusting tests timeout, running only two jobs simultaneously (appveyor gives a vm with two cores, but b2 is invoked with -j3) or perform multiple tries before failing on those timing critical tests.

viboes commented 5 years ago

I'm wondering to remove those unstable test (depending on the time) from the regression tests and execute them only on machines I master.

On the other side I Would need to add tests that replace the real time and this needs a lot of work.