[Lldb-commits] [lldb] [lldb] Add try_lock to SBMutex (PR #164109)
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Mon Oct 20 08:13:21 PDT 2025
================
@@ -58,3 +58,12 @@ void SBMutex::unlock() const {
if (m_opaque_sp)
m_opaque_sp->unlock();
}
+
+bool SBMutex::try_lock() const {
+ LLDB_INSTRUMENT_VA(this);
+
+ if (m_opaque_sp)
----------------
JDevlieghere wrote:
Yes, you're right. If that's the case then I don't think the pointer can be null. Doesn't look like we do this in SBTarget either, but we could update the classes where that's the case to have an assert, but that would be a bigger change.
https://github.com/llvm/llvm-project/pull/164109
More information about the lldb-commits
mailing list