Core: Use fmt where applicable for DebugInterface implementations

These are trivial enough that they're basically one-to-one conversions
with minor changes of syntax.
This commit is contained in:
Lioncash
2019-07-08 18:00:56 -04:00
parent 457bff92c1
commit 98101bbbe4
2 changed files with 8 additions and 6 deletions

View File

@ -7,8 +7,9 @@
#include <cstddef>
#include <string>
#include <fmt/format.h>
#include "Common/MsgHandler.h"
#include "Common/StringUtil.h"
#include "Core/DSP/DSPCore.h"
#include "Core/DSP/DSPMemoryMap.h"
#include "Core/HW/DSPLLE/DSPSymbols.h"
@ -156,7 +157,7 @@ std::string DSPDebugInterface::GetRawMemoryString(int memory, u32 address)
{
case 0:
case 0x8:
return StringFromFormat("%04x", dsp_imem_read(address));
return fmt::format("{:04x}", dsp_imem_read(address));
default:
return "--IMEM--";
}
@ -166,9 +167,9 @@ std::string DSPDebugInterface::GetRawMemoryString(int memory, u32 address)
{
case 0:
case 1:
return StringFromFormat("%04x (DMEM)", dsp_dmem_read(address));
return fmt::format("{:04x} (DMEM)", dsp_dmem_read(address));
case 0xf:
return StringFromFormat("%04x (MMIO)", g_dsp.ifx_regs[address & 0xFF]);
return fmt::format("{:04x} (MMIO)", g_dsp.ifx_regs[address & 0xFF]);
default:
return "--DMEM--";
}