1#ifndef BREAKPOINTBASE_HH
2#define BREAKPOINTBASE_HH
17template<
typename Derived>
21 [[nodiscard]]
unsigned getId()
const {
return id; }
22 [[nodiscard]] std::string
getIdStr()
const {
return strCat(Derived::prefix,
id); }
26 [[nodiscard]]
bool isEnabled()
const {
return enabled; }
27 [[nodiscard]]
bool onlyOnce()
const {
return once; }
41 if (!enabled)
return false;
47 if (isTrue(cliComm, interp)) {
84 bool executing =
false;
86 static inline unsigned lastId = 0;
Assign new value to some variable and restore the original value when this object goes out of scope.
CRTP base class for CPU break and watch points.
void setEnabled(Interpreter &interp, const TclObject &e)
void setOnce(Interpreter &interp, const TclObject &o)
std::string getIdStr() const
TclObject getCommand() const
void setCondition(const TclObject &c)
TclObject getCondition() const
void setCommand(const TclObject &c)
bool checkAndExecute(GlobalCliComm &cliComm, Interpreter &interp)
void printWarning(std::string_view message)
bool getBoolean(Interpreter &interp) const
TclObject executeCommand(Interpreter &interp, bool compile=false)
Interpret this TclObject as a command and execute it.
bool evalBool(Interpreter &interp) const
zstring_view getString() const
constexpr auto empty() const
This file implemented 3 utility functions: