1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-16 20:25:07 +00:00

LibDebug: Move everything into the "Debug" namespace

This commit is contained in:
Luke 2020-08-25 04:33:07 +01:00 committed by Andreas Kling
parent b58ca7cf3d
commit 694b86a4bf
31 changed files with 115 additions and 85 deletions

View file

@ -30,7 +30,7 @@
namespace HackStudio {
NonnullRefPtr<BacktraceModel> BacktraceModel::create(const DebugSession& debug_session, const PtraceRegisters& regs)
NonnullRefPtr<BacktraceModel> BacktraceModel::create(const Debug::DebugSession& debug_session, const PtraceRegisters& regs)
{
return adopt(*new BacktraceModel(create_backtrace(debug_session, regs)));
}
@ -51,7 +51,7 @@ GUI::ModelIndex BacktraceModel::index(int row, int column, const GUI::ModelIndex
return create_index(row, column, &m_frames.at(row));
}
Vector<BacktraceModel::FrameInfo> BacktraceModel::create_backtrace(const DebugSession& debug_session, const PtraceRegisters& regs)
Vector<BacktraceModel::FrameInfo> BacktraceModel::create_backtrace(const Debug::DebugSession& debug_session, const PtraceRegisters& regs)
{
u32 current_ebp = regs.ebp;
u32 current_instruction = regs.eip;
@ -64,7 +64,7 @@ Vector<BacktraceModel::FrameInfo> BacktraceModel::create_backtrace(const DebugSe
}
frames.append({ name, current_instruction, current_ebp });
auto frame_info = StackFrameUtils::get_info(*Debugger::the().session(), current_ebp);
auto frame_info = Debug::StackFrameUtils::get_info(*Debugger::the().session(), current_ebp);
ASSERT(frame_info.has_value());
current_instruction = frame_info.value().return_address;
current_ebp = frame_info.value().next_ebp;