diff options
| author | redi <redi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-07-09 10:13:01 +0000 |
|---|---|---|
| committer | redi <redi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-07-09 10:13:01 +0000 |
| commit | 339db54bdce71adca1d790413745f7e0d557b693 (patch) | |
| tree | 220d98d77838ae389eb4bbbfd1acdd2be8814bea /libstdc++-v3/include/std/thread | |
| parent | 3115bda06f241a032e3e5dca50556203a98767a0 (diff) | |
| download | ppe42-gcc-339db54bdce71adca1d790413745f7e0d557b693.tar.gz ppe42-gcc-339db54bdce71adca1d790413745f7e0d557b693.zip | |
2011-07-09 Jonathan Wakely <jwakely.gcc@gmail.com>
PR libstdc++/49668
* include/std/functional (__bind_simple): Define.
* include/std/future (_Task_setter): Parameterize by type of result
pointer instead of state object.
(_S_task_setter): Type deduction helper.
(_Task_state): Use _S_task_setter and __bind_simple.
(_Deferred_state, _Async_state): Store call wrapper directly not as
std::function. Use _S_task_setter and __bind_simple.
(_S_make_deferred_state, _S_make_async_state): Type deduction helpers.
(async): Use new functions and __bind_simple.
* include/std/mutex (call_once): Use __bind_simple.
* include/std/thread (thread): Likewise. Remove unused headers.
* src/thread.cc: Add header.
* testsuite/30_threads/async/49668.cc: New.
* testsuite/30_threads/call_once/49668.cc: New.
* testsuite/30_threads/thread/cons/49668.cc: New.
* testsuite/30_threads/thread/cons/moveable.cc: Remove unused bool.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@176073 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/include/std/thread')
| -rw-r--r-- | libstdc++-v3/include/std/thread | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/libstdc++-v3/include/std/thread b/libstdc++-v3/include/std/thread index ab85735154e..8cc06903ebf 100644 --- a/libstdc++-v3/include/std/thread +++ b/libstdc++-v3/include/std/thread @@ -38,8 +38,6 @@ #include <chrono> #include <functional> #include <memory> -#include <mutex> -#include <condition_variable> #include <bits/functexcept.h> #include <bits/functional_hash.h> #include <bits/gthr.h> @@ -132,7 +130,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION explicit thread(_Callable&& __f, _Args&&... __args) { - _M_start_thread(_M_make_routine(std::bind<void>( + _M_start_thread(_M_make_routine(std::__bind_simple( std::forward<_Callable>(__f), std::forward<_Args>(__args)...))); } |

