This commit is contained in:
nikitalita 2025-03-11 10:56:45 -07:00
parent ff24f1cd51
commit e4b9aa2b4e
7 changed files with 6 additions and 20 deletions

View file

@ -233,7 +233,6 @@ dap::ResponseOrError<dap::SetBreakpointsResponse> BreakpointManager::SetBreakpoi
continue;
}
}
dap::Breakpoint bpoint;
if (AddBreakpointInfo(actualBin, func, line, instrRef, 0, BreakpointInfo::Type::Line, response.breakpoints))
{
breakpointId = response.breakpoints.back().id.value(-1);

View file

@ -3,11 +3,6 @@
class VMFrameStack;
namespace dap
{
struct Breakpoint;
}
namespace DebugServer
{
namespace RuntimeEvents

View file

@ -27,15 +27,6 @@ static PType * GetElementType(const PType * p_type)
return nullptr;
}
static void* GetArrayHead(const VMValue &value, PType *p_type)
{
if (p_type->isPointer())
{
auto *pointerType = dynamic_cast<PPointer *>(p_type);
return *static_cast<void **>(value.a);
}
return value.a;
}
static int64_t GetElementCount(const VMValue &value, PType *p_type)
{
auto type = p_type;
@ -43,7 +34,6 @@ static int64_t GetElementCount(const VMValue &value, PType *p_type)
if (type->toPointer())
{
type = type->toPointer()->PointedType;
// array_head = *static_cast<void **>(value.a);
}
if (type->isDynArray() || type->isStaticArray())
@ -53,7 +43,6 @@ static int64_t GetElementCount(const VMValue &value, PType *p_type)
return 0;
}
PType* elementType = GetElementType(p_type);
// FArray has the same layout as TArray, just return count
auto *arr = static_cast<FArray *>(array_head);
if (arr->Count == UINT_MAX)

View file

@ -8,7 +8,6 @@
#include <common/scripting/core/symbols.h>
#include <info.h>
#include "DummyNode.h"
static const FString invalidString = FString("<INVALID>");
namespace DebugServer
{

View file

@ -16,7 +16,7 @@ class StructStateNode : public StateNodeBase, public IProtocolVariableSerializab
caseless_path_map<std::shared_ptr<StateNodeBase>> m_children;
void CacheState();
public:
StructStateNode(std::string name, const VMValue value, PType *knownType,const VMFrame * currentFrame = nullptr);
StructStateNode(std::string name, VMValue value, PType *knownType, const VMFrame *currentFrame = nullptr);
bool SerializeToProtocol(dap::Variable &variable) override;

View file

@ -57,7 +57,6 @@ dap::Variable ValueStateNode::ToVariable(const VMValue &m_variable, PType *m_typ
{
PFunction *func = (PFunction *)m_variable.a;
auto *clsName = "<unknown>";
if (func->OwningClass)
{
variable.value += StringFormat("%s.%s (%p)", func->OwningClass->TypeName.GetChars(), func->SymbolName.GetChars(), m_variable.a);

View file

@ -3,6 +3,11 @@
#include "vm.h"
#include "GameEventEmit.h"
namespace dap
{
struct Breakpoint;
}
#define EVENT_DECLARATION(NAME, HANDLER_SIGNATURE) \
typedef std::function<HANDLER_SIGNATURE> NAME## EventHandle; \
NAME##EventHandle SubscribeTo##NAME(std::function<HANDLER_SIGNATURE> handler); \