Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
hrydgard
GitHub Repository: hrydgard/ppsspp
Path: blob/master/Core/Debugger/Watch.h
3658 views
1
#pragma once
2
3
#include <string>
4
#include "Common/Math/expression_parser.h"
5
#include "Core/MIPS/MIPSDebugInterface.h"
6
7
enum class WatchFormat {
8
HEX,
9
INT,
10
FLOAT,
11
STR,
12
};
13
14
struct WatchInfo {
15
WatchInfo() = default;
16
WatchInfo(const std::string &name, const std::string &expr, MIPSDebugInterface *debug, WatchFormat format = WatchFormat::HEX)
17
: name(name), originalExpression(expr), format(format) {
18
initExpression(debug, expr.c_str(), expression);
19
}
20
void SetExpression(const std::string &expr, MIPSDebugInterface *debug) {
21
originalExpression = expr;
22
initExpression(debug, expr.c_str(), expression);
23
}
24
std::string name;
25
std::string originalExpression;
26
PostfixExpression expression;
27
WatchFormat format = WatchFormat::HEX;
28
uint32_t currentValue = 0;
29
uint32_t lastValue = 0;
30
int steppingCounter = -1;
31
bool evaluateFailed = false;
32
};
33
34