Microsoft's C++ Standard Library uses the [[nodiscard]] attribute for try_lock(). See: https://github.com/microsoft/STL/blob/main/stl/inc/mutex
It appears the same issue occurs with GCC 13.1.
Backport of core#26189.
Differential D14005
refactor: Do not discard try_lock() return value Fabien on Jun 7 2023, 13:31. Authored by Tags None Subscribers None
Details
Microsoft's C++ Standard Library uses the [[nodiscard]] attribute for try_lock(). See: https://github.com/microsoft/STL/blob/main/stl/inc/mutex It appears the same issue occurs with GCC 13.1. Backport of core#26189. With debug and GCC 13.1: ninja all check-all It should return no warning.
Diff Detail
|