std::counting_semaphore<LeastMaxValue>::~counting_semaphore

~counting_semaphore();
(C++20 起)

销毁 counting_semaphore 对象。

若任何线程在此信号量上的同时调用任何其他成员函数,则行为未定义。这包括在 acquire()try_acquire_for()try_acquire_until() 中阻塞。