diff --git a/Plugins/UnLua/Source/UnLua/Public/UnLuaEx.inl b/Plugins/UnLua/Source/UnLua/Public/UnLuaEx.inl index e8010e39..d97b0a30 100644 --- a/Plugins/UnLua/Source/UnLua/Public/UnLuaEx.inl +++ b/Plugins/UnLua/Source/UnLua/Public/UnLuaEx.inl @@ -208,7 +208,7 @@ namespace UnLua static int32 Invoke(lua_State *L, const TFunction &Func, TTuple::Type...> &Args, TIndices ParamIndices) { int32 Num = 0; - typename TRemoveConst::Type *RetValPtr = lua_gettop(L) > sizeof...(ArgType) ? UnLua::Get(L, sizeof...(ArgType) + 1, TType::Type*>()) : nullptr; + typename std::remove_cv::type *RetValPtr = lua_gettop(L) > sizeof...(ArgType) ? UnLua::Get(L, sizeof...(ArgType) + 1, TType::type*>()) : nullptr; if (RetValPtr) { *RetValPtr = UnLua::Invoke(Func, Args, typename TZeroBasedIndices::Type());