aboutsummaryrefslogtreecommitdiff
path: root/contrib/llvm-project/lldb/include/lldb/Breakpoint/Breakpoint.h
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/llvm-project/lldb/include/lldb/Breakpoint/Breakpoint.h')
-rw-r--r--contrib/llvm-project/lldb/include/lldb/Breakpoint/Breakpoint.h20
1 files changed, 8 insertions, 12 deletions
diff --git a/contrib/llvm-project/lldb/include/lldb/Breakpoint/Breakpoint.h b/contrib/llvm-project/lldb/include/lldb/Breakpoint/Breakpoint.h
index d29d21070fd7..ddb70b719d6e 100644
--- a/contrib/llvm-project/lldb/include/lldb/Breakpoint/Breakpoint.h
+++ b/contrib/llvm-project/lldb/include/lldb/Breakpoint/Breakpoint.h
@@ -20,6 +20,7 @@
#include "lldb/Breakpoint/BreakpointName.h"
#include "lldb/Breakpoint/BreakpointOptions.h"
#include "lldb/Breakpoint/Stoppoint.h"
+#include "lldb/Breakpoint/StoppointHitCounter.h"
#include "lldb/Core/SearchFilter.h"
#include "lldb/Utility/Event.h"
#include "lldb/Utility/StringList.h"
@@ -544,7 +545,7 @@ public:
/// if the condition says to stop and false otherwise.
///
void SetPrecondition(lldb::BreakpointPreconditionSP precondition_sp) {
- m_precondition_sp = precondition_sp;
+ m_precondition_sp = std::move(precondition_sp);
}
bool EvaluatePrecondition(StoppointCallbackContext &context);
@@ -624,13 +625,6 @@ protected:
bool IgnoreCountShouldStop();
- void IncrementHitCount() { m_hit_count++; }
-
- void DecrementHitCount() {
- assert(m_hit_count > 0);
- m_hit_count--;
- }
-
private:
// To call from CopyFromBreakpoint.
Breakpoint(Target &new_target, const Breakpoint &bp_to_copy_from);
@@ -660,10 +654,12 @@ private:
m_locations; // The list of locations currently found for this breakpoint.
std::string m_kind_description;
bool m_resolve_indirect_symbols;
- uint32_t m_hit_count; // Number of times this breakpoint/watchpoint has been
- // hit. This is kept
- // separately from the locations hit counts, since locations can go away when
- // their backing library gets unloaded, and we would lose hit counts.
+
+ /// Number of times this breakpoint has been hit. This is kept separately
+ /// from the locations hit counts, since locations can go away when their
+ /// backing library gets unloaded, and we would lose hit counts.
+ StoppointHitCounter m_hit_counter;
+
BreakpointName::Permissions m_permissions;
void SendBreakpointChangedEvent(lldb::BreakpointEventType eventKind);