diff --git a/Utilities/BEType.h b/Utilities/BEType.h index f8375351b8..d2dc61b663 100644 --- a/Utilities/BEType.h +++ b/Utilities/BEType.h @@ -197,13 +197,13 @@ class to_be_t template struct _be_type_selector { - typedef typename TT type; + typedef TT type; }; template struct _be_type_selector { - typedef typename be_t type; + typedef be_t type; }; public: diff --git a/rpcs3/Emu/Memory/vm_ptr.h b/rpcs3/Emu/Memory/vm_ptr.h index 50a2cc9780..c7dd6d2c0e 100644 --- a/rpcs3/Emu/Memory/vm_ptr.h +++ b/rpcs3/Emu/Memory/vm_ptr.h @@ -312,6 +312,11 @@ namespace vm } }; + namespace ps3 + { + template class ptr; + } + template class _ptr_base { @@ -329,7 +334,16 @@ namespace vm template struct _func_arg<_ptr_base> { - __forceinline static u64 get_value(const _ptr_base arg) + __forceinline static u64 get_value(const _ptr_base& arg) + { + return arg.addr(); + } + }; + + template + struct _func_arg> + { + __forceinline static u64 get_value(const ps3::ptr& arg) { return arg.addr(); } @@ -338,7 +352,7 @@ namespace vm template struct _func_arg<_ref_base> { - __forceinline static u64 get_value(const _ref_base arg) + __forceinline static u64 get_value(const _ref_base& arg) { return arg.addr(); } @@ -349,7 +363,7 @@ namespace vm { static_assert(!i, "Invalid callback argument type (mem_ptr_t), use vm::ptr"); - __forceinline static u64 get_value(const mem_ptr_t arg) + __forceinline static u64 get_value(const mem_ptr_t& arg) { return 0; }