general: Convert assertion macros over to be fmt-compatible

This commit is contained in:
Lioncash 2018-04-27 07:54:05 -04:00
parent 3c40496409
commit 8475496630
No known key found for this signature in database
GPG key ID: 4E3C3CC1031BA9C7
17 changed files with 39 additions and 39 deletions

View file

@ -76,7 +76,7 @@ public:
case Dynarmic::A64::Exception::Yield:
return;
default:
ASSERT_MSG(false, "ExceptionRaised(exception = %zu, pc = %" PRIx64 ")",
ASSERT_MSG(false, "ExceptionRaised(exception = {}, pc = {:X})",
static_cast<size_t>(exception), pc);
}
}

View file

@ -30,7 +30,7 @@ LoadDll LoadDll::g_load_dll;
#define CHECKED(expr) \
do { \
if (auto _cerr = (expr)) { \
ASSERT_MSG(false, "Call " #expr " failed with error: %u (%s)\n", _cerr, \
ASSERT_MSG(false, "Call " #expr " failed with error: {} ({})\n", _cerr, \
uc_strerror(_cerr)); \
} \
} while (0)
@ -53,7 +53,7 @@ static bool UnmappedMemoryHook(uc_engine* uc, uc_mem_type type, u64 addr, int si
void* user_data) {
ARM_Interface::ThreadContext ctx{};
Core::CPU().SaveContext(ctx);
ASSERT_MSG(false, "Attempted to read from unmapped memory: 0x%lx, pc=0x%lx, lr=0x%lx", addr,
ASSERT_MSG(false, "Attempted to read from unmapped memory: {:#X}, pc={:#X}, lr={:#X}", addr,
ctx.pc, ctx.cpu_registers[30]);
return {};
}