|
333 | 333 | public:
|
334 | 334 | // types:
|
335 | 335 | class id;
|
336 |
| - using native_handle_type = @\impdef@; // See~\ref{thread.req.native} |
| 336 | + using native_handle_type = @\impdefnc@; // see~\ref{thread.req.native} |
337 | 337 |
|
338 | 338 | // construct/copy/destroy:
|
339 | 339 | thread() noexcept;
|
|
350 | 350 | void join();
|
351 | 351 | void detach();
|
352 | 352 | id get_id() const noexcept;
|
353 |
| - native_handle_type native_handle(); // See~\ref{thread.req.native} |
| 353 | + native_handle_type native_handle(); // see~\ref{thread.req.native} |
354 | 354 |
|
355 | 355 | // static members:
|
356 |
| - static unsigned hardware_concurrency() noexcept; |
| 356 | + static unsigned int hardware_concurrency() noexcept; |
357 | 357 | };
|
358 | 358 | }
|
359 | 359 | \end{codeblock}
|
|
366 | 366 | namespace std {
|
367 | 367 | class thread::id {
|
368 | 368 | public:
|
369 |
| - id() noexcept; |
| 369 | + id() noexcept; |
370 | 370 | };
|
371 | 371 |
|
372 | 372 | bool operator==(thread::id x, thread::id y) noexcept;
|
|
378 | 378 |
|
379 | 379 | template<class charT, class traits>
|
380 | 380 | basic_ostream<charT, traits>&
|
381 |
| - operator<< (basic_ostream<charT, traits>& out, thread::id id); |
| 381 | + operator<<(basic_ostream<charT, traits>& out, thread::id id); |
382 | 382 |
|
383 | 383 | // Hash support
|
384 | 384 | template <class T> struct hash;
|
|
1036 | 1036 | bool try_lock();
|
1037 | 1037 | void unlock();
|
1038 | 1038 |
|
1039 |
| - using native_handle_type = @\impdefnc@; // See~\ref{thread.req.native} |
1040 |
| - native_handle_type native_handle(); // See~\ref{thread.req.native} |
| 1039 | + using native_handle_type = @\impdefnc@; // see~\ref{thread.req.native} |
| 1040 | + native_handle_type native_handle(); // see~\ref{thread.req.native} |
1041 | 1041 | };
|
1042 | 1042 | }
|
1043 | 1043 | \end{codeblock}
|
|
1091 | 1091 | bool try_lock() noexcept;
|
1092 | 1092 | void unlock();
|
1093 | 1093 |
|
1094 |
| - using native_handle_type = @\impdefnc@; // See~\ref{thread.req.native} |
1095 |
| - native_handle_type native_handle(); // See~\ref{thread.req.native} |
| 1094 | + using native_handle_type = @\impdefnc@; // see~\ref{thread.req.native} |
| 1095 | + native_handle_type native_handle(); // see~\ref{thread.req.native} |
1096 | 1096 | };
|
1097 | 1097 | }
|
1098 | 1098 | \end{codeblock}
|
|
1223 | 1223 | timed_mutex(const timed_mutex&) = delete;
|
1224 | 1224 | timed_mutex& operator=(const timed_mutex&) = delete;
|
1225 | 1225 |
|
1226 |
| - void lock(); // blocking |
| 1226 | + void lock(); // blocking |
1227 | 1227 | bool try_lock();
|
1228 | 1228 | template <class Rep, class Period>
|
1229 | 1229 | bool try_lock_for(const chrono::duration<Rep, Period>& rel_time);
|
1230 | 1230 | template <class Clock, class Duration>
|
1231 | 1231 | bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time);
|
1232 | 1232 | void unlock();
|
1233 | 1233 |
|
1234 |
| - using native_handle_type = @\impdefnc@; // See~\ref{thread.req.native} |
1235 |
| - native_handle_type native_handle(); // See~\ref{thread.req.native} |
| 1234 | + using native_handle_type = @\impdefnc@; // see~\ref{thread.req.native} |
| 1235 | + native_handle_type native_handle(); // see~\ref{thread.req.native} |
1236 | 1236 | };
|
1237 | 1237 | }
|
1238 | 1238 | \end{codeblock}
|
|
1274 | 1274 | recursive_timed_mutex(const recursive_timed_mutex&) = delete;
|
1275 | 1275 | recursive_timed_mutex& operator=(const recursive_timed_mutex&) = delete;
|
1276 | 1276 |
|
1277 |
| - void lock(); // blocking |
| 1277 | + void lock(); // blocking |
1278 | 1278 | bool try_lock() noexcept;
|
1279 | 1279 | template <class Rep, class Period>
|
1280 | 1280 | bool try_lock_for(const chrono::duration<Rep, Period>& rel_time);
|
1281 | 1281 | template <class Clock, class Duration>
|
1282 | 1282 | bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time);
|
1283 | 1283 | void unlock();
|
1284 | 1284 |
|
1285 |
| - using native_handle_type = @\impdefnc@; // See~\ref{thread.req.native} |
1286 |
| - native_handle_type native_handle(); // See~\ref{thread.req.native} |
| 1285 | + using native_handle_type = @\impdefnc@; // see~\ref{thread.req.native} |
| 1286 | + native_handle_type native_handle(); // see~\ref{thread.req.native} |
1287 | 1287 | };
|
1288 | 1288 | }
|
1289 | 1289 | \end{codeblock}
|
|
1444 | 1444 | shared_mutex& operator=(const shared_mutex&) = delete;
|
1445 | 1445 |
|
1446 | 1446 | // Exclusive ownership
|
1447 |
| - void lock(); // blocking |
| 1447 | + void lock(); // blocking |
1448 | 1448 | bool try_lock();
|
1449 | 1449 | void unlock();
|
1450 | 1450 |
|
|
1453 | 1453 | bool try_lock_shared();
|
1454 | 1454 | void unlock_shared();
|
1455 | 1455 |
|
1456 |
| - using native_handle_type = @\impdefnc@; // See~\ref{thread.req.native} |
1457 |
| - native_handle_type native_handle(); // See~\ref{thread.req.native} |
| 1456 | + using native_handle_type = @\impdefnc@; // see~\ref{thread.req.native} |
| 1457 | + native_handle_type native_handle(); // see~\ref{thread.req.native} |
1458 | 1458 | };
|
1459 | 1459 | }
|
1460 | 1460 | \end{codeblock}
|
|
1579 | 1579 | shared_timed_mutex& operator=(const shared_timed_mutex&) = delete;
|
1580 | 1580 |
|
1581 | 1581 | // Exclusive ownership
|
1582 |
| - void lock(); // blocking |
| 1582 | + void lock(); // blocking |
1583 | 1583 | bool try_lock();
|
1584 | 1584 | template <class Rep, class Period>
|
1585 | 1585 | bool try_lock_for(const chrono::duration<Rep, Period>& rel_time);
|
|
1588 | 1588 | void unlock();
|
1589 | 1589 |
|
1590 | 1590 | // Shared ownership
|
1591 |
| - void lock_shared(); // blocking |
| 1591 | + void lock_shared(); // blocking |
1592 | 1592 | bool try_lock_shared();
|
1593 | 1593 | template <class Rep, class Period>
|
1594 |
| - bool |
1595 |
| - try_lock_shared_for(const chrono::duration<Rep, Period>& rel_time); |
| 1594 | + bool try_lock_shared_for(const chrono::duration<Rep, Period>& rel_time); |
1596 | 1595 | template <class Clock, class Duration>
|
1597 |
| - bool |
1598 |
| - try_lock_shared_until(const chrono::time_point<Clock, Duration>& abs_time); |
| 1596 | + bool try_lock_shared_until(const chrono::time_point<Clock, Duration>& abs_time); |
1599 | 1597 | void unlock_shared();
|
1600 | 1598 | };
|
1601 | 1599 | }
|
|
1671 | 1669 | lock_guard& operator=(const lock_guard&) = delete;
|
1672 | 1670 |
|
1673 | 1671 | private:
|
1674 |
| - mutex_type& pm; // \expos |
| 1672 | + mutex_type& pm; // \expos |
1675 | 1673 | };
|
1676 | 1674 |
|
1677 | 1675 | template<class Mutex> lock_guard(lock_guard<Mutex>) -> lock_guard<Mutex>;
|
|
1739 | 1737 | template <class... MutexTypes>
|
1740 | 1738 | class scoped_lock {
|
1741 | 1739 | public:
|
1742 |
| - using mutex_type = Mutex; // If \tcode{MutexTypes...} consists of the single type \tcode{Mutex} |
| 1740 | + using mutex_type = Mutex; // If \tcode{MutexTypes...} consists of the single type \tcode{Mutex} |
1743 | 1741 |
|
1744 | 1742 | explicit scoped_lock(MutexTypes&... m);
|
1745 | 1743 | explicit scoped_lock(adopt_lock_t, MutexTypes&... m);
|
|
1749 | 1747 | scoped_lock& operator=(const scoped_lock&) = delete;
|
1750 | 1748 |
|
1751 | 1749 | private:
|
1752 |
| - tuple<MutexTypes&...> pm; // \expos |
| 1750 | + tuple<MutexTypes&...> pm; // \expos |
1753 | 1751 | };
|
1754 | 1752 |
|
1755 | 1753 | template<class... MutexTypes>
|
|
1863 | 1861 | mutex_type* mutex() const noexcept;
|
1864 | 1862 |
|
1865 | 1863 | private:
|
1866 |
| - mutex_type* pm; // \expos |
1867 |
| - bool owns; // \expos |
| 1864 | + mutex_type* pm; // \expos |
| 1865 | + bool owns; // \expos |
1868 | 1866 | };
|
1869 | 1867 |
|
1870 | 1868 | template<class Mutex> unique_lock(unique_lock<Mutex>) -> unique_lock<Mutex>;
|
|
2271 | 2269 |
|
2272 | 2270 | // \ref{thread.lock.shared.cons}, construct/copy/destroy
|
2273 | 2271 | shared_lock() noexcept;
|
2274 |
| - explicit shared_lock(mutex_type& m); // blocking |
| 2272 | + explicit shared_lock(mutex_type& m); // blocking |
2275 | 2273 | shared_lock(mutex_type& m, defer_lock_t) noexcept;
|
2276 | 2274 | shared_lock(mutex_type& m, try_to_lock_t);
|
2277 | 2275 | shared_lock(mutex_type& m, adopt_lock_t);
|
2278 | 2276 | template <class Clock, class Duration>
|
2279 |
| - shared_lock(mutex_type& m, |
2280 |
| - const chrono::time_point<Clock, Duration>& abs_time); |
| 2277 | + shared_lock(mutex_type& m, const chrono::time_point<Clock, Duration>& abs_time); |
2281 | 2278 | template <class Rep, class Period>
|
2282 |
| - shared_lock(mutex_type& m, |
2283 |
| - const chrono::duration<Rep, Period>& rel_time); |
| 2279 | + shared_lock(mutex_type& m, const chrono::duration<Rep, Period>& rel_time); |
2284 | 2280 | ~shared_lock();
|
2285 | 2281 |
|
2286 | 2282 | shared_lock(const shared_lock&) = delete;
|
|
2290 | 2286 | shared_lock& operator=(shared_lock&& u) noexcept;
|
2291 | 2287 |
|
2292 | 2288 | // \ref{thread.lock.shared.locking}, locking
|
2293 |
| - void lock(); // blocking |
| 2289 | + void lock(); // blocking |
2294 | 2290 | bool try_lock();
|
2295 | 2291 | template <class Rep, class Period>
|
2296 | 2292 | bool try_lock_for(const chrono::duration<Rep, Period>& rel_time);
|
|
2308 | 2304 | mutex_type* mutex() const noexcept;
|
2309 | 2305 |
|
2310 | 2306 | private:
|
2311 |
| - mutex_type* pm; // \expos |
2312 |
| - bool owns; // \expos |
| 2307 | + mutex_type* pm; // \expos |
| 2308 | + bool owns; // \expos |
2313 | 2309 | };
|
2314 | 2310 |
|
2315 | 2311 | template<class Mutex> shared_lock(shared_lock<Mutex>) -> shared_lock<Mutex>;
|
|
2551 | 2547 | \indexlibrarymember{try_lock_until}{shared_lock}%
|
2552 | 2548 | \begin{itemdecl}
|
2553 | 2549 | template <class Clock, class Duration>
|
2554 |
| - bool |
2555 |
| - try_lock_until(const chrono::time_point<Clock, Duration>& abs_time); |
| 2550 | + bool try_lock_until(const chrono::time_point<Clock, Duration>& abs_time); |
2556 | 2551 | \end{itemdecl}
|
2557 | 2552 |
|
2558 | 2553 | \begin{itemdescr}
|
|
2963 | 2958 | namespace std {
|
2964 | 2959 | class condition_variable {
|
2965 | 2960 | public:
|
2966 |
| - |
2967 | 2961 | condition_variable();
|
2968 | 2962 | ~condition_variable();
|
2969 | 2963 |
|
|
2982 | 2976 | bool wait_until(unique_lock<mutex>& lock,
|
2983 | 2977 | const chrono::time_point<Clock, Duration>& abs_time,
|
2984 | 2978 | Predicate pred);
|
2985 |
| - |
2986 | 2979 | template <class Rep, class Period>
|
2987 | 2980 | cv_status wait_for(unique_lock<mutex>& lock,
|
2988 | 2981 | const chrono::duration<Rep, Period>& rel_time);
|
|
2991 | 2984 | const chrono::duration<Rep, Period>& rel_time,
|
2992 | 2985 | Predicate pred);
|
2993 | 2986 |
|
2994 |
| - using native_handle_type = @\impdefnc@; // See~\ref{thread.req.native} |
2995 |
| - native_handle_type native_handle(); // See~\ref{thread.req.native} |
| 2987 | + using native_handle_type = @\impdefnc@; // see~\ref{thread.req.native} |
| 2988 | + native_handle_type native_handle(); // see~\ref{thread.req.native} |
2996 | 2989 | };
|
2997 | 2990 | }
|
2998 | 2991 | \end{codeblock}
|
|
3371 | 3364 | cv_status wait_until(Lock& lock, const chrono::time_point<Clock, Duration>& abs_time);
|
3372 | 3365 | template <class Lock, class Clock, class Duration, class Predicate>
|
3373 | 3366 | bool wait_until(Lock& lock, const chrono::time_point<Clock, Duration>& abs_time,
|
3374 |
| - Predicate pred); |
| 3367 | + Predicate pred); |
3375 | 3368 | template <class Lock, class Rep, class Period>
|
3376 | 3369 | cv_status wait_for(Lock& lock, const chrono::duration<Rep, Period>& rel_time);
|
3377 | 3370 | template <class Lock, class Rep, class Period, class Predicate>
|
3378 |
| - bool wait_for(Lock& lock, const chrono::duration<Rep, Period>& rel_time, |
3379 |
| - Predicate pred); |
| 3371 | + bool wait_for(Lock& lock, const chrono::duration<Rep, Period>& rel_time, Predicate pred); |
3380 | 3372 | };
|
3381 | 3373 | }
|
3382 | 3374 | \end{codeblock}
|
|
3751 | 3743 |
|
3752 | 3744 | const error_code& code() const noexcept;
|
3753 | 3745 | const char* what() const noexcept;
|
| 3746 | + |
3754 | 3747 | private:
|
3755 |
| - error_code ec_; // \expos |
| 3748 | + error_code ec_; // \expos |
3756 | 3749 | };
|
3757 | 3750 | }
|
3758 | 3751 | \end{codeblock}
|
|
3931 | 3924 | void set_value_at_thread_exit(@\seebelow@);
|
3932 | 3925 | void set_exception_at_thread_exit(exception_ptr p);
|
3933 | 3926 | };
|
| 3927 | + |
3934 | 3928 | template <class R>
|
3935 | 3929 | void swap(promise<R>& x, promise<R>& y) noexcept;
|
| 3930 | + |
3936 | 3931 | template <class R, class Alloc>
|
3937 | 3932 | struct uses_allocator<promise<R>, Alloc>;
|
3938 | 3933 | }
|
|
5010 | 5005 |
|
5011 | 5006 | void reset();
|
5012 | 5007 | };
|
| 5008 | + |
5013 | 5009 | template <class R, class... ArgTypes>
|
5014 | 5010 | void swap(packaged_task<R(ArgTypes...)>& x, packaged_task<R(ArgTypes...)>& y) noexcept;
|
| 5011 | + |
5015 | 5012 | template <class R, class Alloc>
|
5016 | 5013 | struct uses_allocator<packaged_task<R>, Alloc>;
|
5017 | 5014 | }
|
|
0 commit comments