问题描述
很显然,我们仍然会维护它,但是一旦C ++标准保证了它就会有用。
Obviously we will still maintain it, but how useful will it be, once the C++ standard guarantees is.
关于同步原语(Mutex,条件变量)的说明
What about synchronization primitives (Mutex, conditional variables) with advent of the new standard?
您认为pthread相对于std :: thread较难掌握吗?
推荐答案
C不会消失。 POSIX不会消失。用C语言为POSIX编写的多线程代码不会消失。所以pthread不会消失。
C isn't going away. POSIX isn't going away. Multithreaded code written in C for POSIX isn't going away. So pthreads isn't going away.
很多std :: thread的实现都会在后台使用pthread。
Many implementations of std::thread will use pthreads under the hood.
Pthreads API是在ANSI / IEEE POSIX 1003.1-1995标准中定义的。 -POSIX线程编程
"The Pthreads API is defined in the ANSI/IEEE POSIX 1003.1 - 1995 standard." -- POSIX Threads Programming https://computing.llnl.gov/tutorials/pthreads/
这篇关于一旦std:thread变成C ++ Ox,pthreads会过时吗的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!