Mark MutexLock as [[nodiscard]] to prevent misuse.

This commit is contained in:
X23 2026-02-14 18:28:27 +08:00
parent bf95b62586
commit 27393fbd24

View file

@ -69,7 +69,7 @@ public:
};
template <typename MutexT>
class MutexLock {
class [[nodiscard]] MutexLock {
mutable THREADING_NAMESPACE::unique_lock<typename MutexT::StdMutexType> lock;
public:
@ -114,7 +114,7 @@ public:
};
template <typename MutexT>
class MutexLock {
class [[nodiscard]] MutexLock {
public:
MutexLock(const MutexT &p_mutex) {}