================
@@ -67,18 +67,15 @@ size_t WatchpointResource::GetNumberOfOwners() {
bool WatchpointResource::OwnersContains(WatchpointSP &wp_sp) {
std::lock_guard<std::recursive_mutex> guard(m_owners_mutex);
const auto &it = std::find(m_owners.begin(), m_owners.end(), wp_sp);
- if (it != m_owners.end())
- return true;
- return false;
+ return it != m_owners.end();
}
bool WatchpointResource::OwnersContains(const Watchpoint *wp) {
std::lock_guard<std::recursive_mutex> guard(m_owners_mutex);
- for (WatchpointCollection::const_iterator it = m_owners.begin();
- it != m_owners.end(); ++it)
- if ((*it).get() == wp)
- return true;
- return false;
+ WatchpointCollection::const_iterator match =
----------------
bulbazord wrote:
Looks fine, but the type should be different right? I think you removed
`WatchpointCollection` in the 3rd commit
https://github.com/llvm/llvm-project/pull/68845
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits