Make ConcurrentQueue::waitAll() const

This member function does not affect the logical state of the class.
Making std::condition_variable and std::mutex data members mutable is
idiomatic as these classes are thread-safe synchronization primitives.
This commit is contained in:
Igor Kushnir
2021-03-18 11:30:55 +02:00
committed by Luis Ángel San Martín
parent 72c78d0164
commit 05b384ed6d
3 changed files with 5 additions and 5 deletions

View File

@ -202,7 +202,7 @@ std::size_t cancelAndPrint(ConcurrentQueue &queue, const QueueControlMessagePrin
return canceledCount;
}
void waitAndPrint(ConcurrentQueue &queue, const QueueControlMessagePrinter &printer)
void waitAndPrint(const ConcurrentQueue &queue, const QueueControlMessagePrinter &printer)
{
printer.printBeginWaitingMessage();
queue.waitAll();