common: Convert type traits templates over to variable template versions where applicable
Uses the C++17 inline variable variants
This commit is contained in:
parent
825e8cb925
commit
a7d6efc520
5 changed files with 11 additions and 11 deletions
|
@ -34,7 +34,7 @@ inline bool IsWithin2G(const Xbyak::CodeGenerator& code, uintptr_t target) {
|
|||
|
||||
template <typename T>
|
||||
inline void CallFarFunction(Xbyak::CodeGenerator& code, const T f) {
|
||||
static_assert(std::is_pointer<T>(), "Argument must be a (function) pointer.");
|
||||
static_assert(std::is_pointer_v<T>, "Argument must be a (function) pointer.");
|
||||
size_t addr = reinterpret_cast<size_t>(f);
|
||||
if (IsWithin2G(code, addr)) {
|
||||
code.call(f);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue