diff --git a/parallel/queue.hpp b/parallel/queue.hpp index 46ae8f07..3f6a7e56 100644 --- a/parallel/queue.hpp +++ b/parallel/queue.hpp @@ -66,7 +66,7 @@ namespace util::parallel { /// if updating the write pointer fails we bail and return false. /// else, we will be able to commit the data and return true. bool - push (const ValueT &val) + push [[nodiscard]] (const ValueT &val) { do { // find our current and next indices, checking there is @@ -119,7 +119,7 @@ namespace util::parallel { /// importantly: the contents of the provided reference may have been /// overwritten, but should not be used unless true was returned. bool - pop (ValueT &out) + pop [[nodiscard]] (ValueT &out) { do {