Skip to content

Commit

Permalink
[unreal]模板绑定时,-操作符导致的错误
Browse files Browse the repository at this point in the history
  • Loading branch information
chexiongsheng committed Nov 11, 2024
1 parent 9d62ee3 commit 7f560be
Showing 1 changed file with 19 additions and 18 deletions.
37 changes: 19 additions & 18 deletions unreal/Puerts/Source/JsEnv/Public/ScriptBackend.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@
#define MakeVariable(M) MakeProperty(M)
#define MakeVariableByGetterSetter(M) MakePropertyByGetterSetter(M)
#define MakeReadonlyVariable(M) MakeReadonlyProperty(M)
#define MakeFunction(M, ...) \
[](::PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API::CallbackInfoType info) \
{ \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M>::callWithDefaultValues( \
info, ##__VA_ARGS__); \
}, \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M>::info( \
#define MakeFunction(M, ...) \
[](::PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API::CallbackInfoType info) \
{ \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M, \
false>::callWithDefaultValues(info, ##__VA_ARGS__); \
}, \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M, false>::info( \
PUERTS_NAMESPACE::Count(__VA_ARGS__))
#define MakeExtension(M, ...) \
[](::PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API::CallbackInfoType info) \
Expand All @@ -59,13 +59,13 @@
}, \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M>::extensionInfo( \
PUERTS_NAMESPACE::Count(__VA_ARGS__))
#define SelectFunction(SIGNATURE, M, ...) \
[](::PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API::CallbackInfoType info) \
{ \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, SIGNATURE, M>::callWithDefaultValues( \
info, ##__VA_ARGS__); \
}, \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, SIGNATURE, M>::info( \
#define SelectFunction(SIGNATURE, M, ...) \
[](::PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API::CallbackInfoType info) \
{ \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, SIGNATURE, M, \
false>::callWithDefaultValues(info, ##__VA_ARGS__); \
}, \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, SIGNATURE, M, false>::info( \
PUERTS_NAMESPACE::Count(__VA_ARGS__))
#define SelectFunction_PtrRet(SIGNATURE, M, ...) \
[](::PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API::CallbackInfoType info) \
Expand All @@ -75,10 +75,11 @@
}, \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, SIGNATURE, M, true>::info( \
PUERTS_NAMESPACE::Count(__VA_ARGS__))
#define MakeCheckFunction(M) \
&(::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M>::checkedCall), \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M>::info()
#define MakeOverload(SIGNATURE, M) PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, SIGNATURE, M>
#define MakeCheckFunction(M) \
&(::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M, false>::checkedCall), \
::PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, decltype(M), M, false>::info()
#define MakeOverload(SIGNATURE, M) \
PUERTS_NAMESPACE::FuncCallWrapper<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, SIGNATURE, M, false>
#define CombineOverloads(...) \
&::PUERTS_NAMESPACE::OverloadsCombiner<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, __VA_ARGS__>::call, \
::PUERTS_NAMESPACE::OverloadsCombiner<PUERTS_NAMESPACE::PUERTS_BINDING_IMPL::API, __VA_ARGS__>::length, \
Expand Down

0 comments on commit 7f560be

Please sign in to comment.