[libcxx] Fix building for windows after 54fa9ecd3088508
authorMartin Storsjö <martin@martin.st>
Tue, 25 Feb 2020 07:36:24 +0000 (09:36 +0200)
committerMartin Storsjö <martin@martin.st>
Tue, 25 Feb 2020 19:33:52 +0000 (21:33 +0200)
commite3add3e5a192ec7f73922a4278f52d335d1f9be5
treeec38ed48d8aee6b1b535825a49032fa00313ad21
parent922558be9ecb24f51fbe879bf6e55d6aad9f4619
[libcxx] Fix building for windows after 54fa9ecd3088508

Move the implementation of __libcpp_thread_poll_with_backoff
and __libcpp_timed_backoff_policy::operator() out of the
_LIBCPP_HAS_THREAD_API_PTHREAD block. None of the code in these
methods is pthreads specific.

Also add "inline _LIBCPP_INLINE_VISIBILITY" to
__libcpp_timed_backoff_policy::operator(), to avoid errors due to
multiple definitions of the operator. Contrary to
__libcpp_thread_poll_with_backoff (which is a template function),
this is a normal non-templated method.

Differential Revision: https://reviews.llvm.org/D75102
libcxx/include/__threading_support