diff --git a/Source/Core/Common/Arm64Emitter.h b/Source/Core/Common/Arm64Emitter.h index 6db19dc890..6939984308 100644 --- a/Source/Core/Common/Arm64Emitter.h +++ b/Source/Core/Common/Arm64Emitter.h @@ -711,10 +711,9 @@ public: // (this method might be a thunk in the case of multi-inheritance) so we // have to go through a trampoline function. template - static void CallLambdaTrampoline(const std::function* f, - Args... args) + static T CallLambdaTrampoline(const std::function* f, Args... args) { - (*f)(args...); + return (*f)(args...); } // This function expects you to have set up the state. diff --git a/Source/Core/Common/x64Emitter.h b/Source/Core/Common/x64Emitter.h index 7e3b64f49e..f6faea44bd 100644 --- a/Source/Core/Common/x64Emitter.h +++ b/Source/Core/Common/x64Emitter.h @@ -971,10 +971,9 @@ public: // (this method might be a thunk in the case of multi-inheritance) so we // have to go through a trampoline function. template - static void CallLambdaTrampoline(const std::function* f, - Args... args) + static T CallLambdaTrampoline(const std::function* f, Args... args) { - (*f)(args...); + return (*f)(args...); } template