- { return _M_id._M_thread; }
-
- // Returns a value that hints at the number of hardware thread contexts.
- static unsigned int
- hardware_concurrency()
- { return 0; }
-
- private:
- void
- _M_start_thread(__shared_base_type);
-
- template<typename _Callable>
- shared_ptr<_Impl<_Callable>>
- _M_make_routine(_Callable&& __f)
- {
- // Create and allocate full data structure, not base.
- return make_shared<_Impl<_Callable>>(std::forward<_Callable>(__f));
- }
- };
-
- inline thread::_Impl_base::~_Impl_base() = default;
-
- inline void
- swap(thread& __x, thread& __y)
- { __x.swap(__y); }
-
- inline bool
- operator!=(thread::id __x, thread::id __y)
- { return !(__x == __y); }
-
- inline bool
- operator<=(thread::id __x, thread::id __y)
- { return !(__y < __x); }
-
- inline bool
- operator>(thread::id __x, thread::id __y)
- { return __y < __x; }
-
- inline bool
- operator>=(thread::id __x, thread::id __y)
- { return !(__x < __y); }
-
- // DR 889.
- /// std::hash specialization for thread::id.
- template<>
- struct hash<thread::id>
- : public __hash_base<size_t, thread::id>