mirror of https://github.com/PCSX2/pcsx2.git
Common: Fix unused function warning
This commit is contained in:
parent
88f8ef0244
commit
4aaf6ba69e
|
@ -40,16 +40,18 @@
|
|||
}; \
|
||||
};
|
||||
|
||||
template<typename T> static T GetBufferT(u8* buffer, u32 offset) {
|
||||
template <typename T>
|
||||
[[maybe_unused]] __fi static T GetBufferT(u8* buffer, u32 offset)
|
||||
{
|
||||
T value;
|
||||
std::memcpy(&value, buffer + offset, sizeof(value));
|
||||
return value;
|
||||
}
|
||||
|
||||
static u8 GetBufferU8(u8* buffer, u32 offset) { return GetBufferT<u8>(buffer, offset); }
|
||||
static u16 GetBufferU16(u8* buffer, u32 offset) { return GetBufferT<u16>(buffer, offset); }
|
||||
static u32 GetBufferU32(u8* buffer, u32 offset) { return GetBufferT<u32>(buffer, offset); }
|
||||
static u64 GetBufferU64(u8* buffer, u32 offset) { return GetBufferT<u64>(buffer, offset); }
|
||||
[[maybe_unused]] __fi static u8 GetBufferU8(u8* buffer, u32 offset) { return GetBufferT<u8>(buffer, offset); }
|
||||
[[maybe_unused]] __fi static u16 GetBufferU16(u8* buffer, u32 offset) { return GetBufferT<u16>(buffer, offset); }
|
||||
[[maybe_unused]] __fi static u32 GetBufferU32(u8* buffer, u32 offset) { return GetBufferT<u32>(buffer, offset); }
|
||||
[[maybe_unused]] __fi static u64 GetBufferU64(u8* buffer, u32 offset) { return GetBufferT<u64>(buffer, offset); }
|
||||
|
||||
// --------------------------------------------------------------------------------------
|
||||
// PageProtectionMode
|
||||
|
|
Loading…
Reference in New Issue