mirror of
https://github.com/ThePhD/sol2.git
synced 2024-03-22 13:10:44 +08:00
If you want to have return types, use .call
instead of operator()
.
This commit is contained in:
parent
c6f6203ab2
commit
49ad128493
|
@ -65,11 +65,6 @@ public:
|
|||
void operator()(Args&&... args) {
|
||||
call<>(std::forward<Args>(args)...);
|
||||
}
|
||||
|
||||
template<typename... Ret, typename... Args>
|
||||
auto operator()(types<Ret...>, Args&&... args) {
|
||||
return call<Ret...>(std::forward<Args>(args)...);
|
||||
}
|
||||
|
||||
template<typename... Ret, typename... Args>
|
||||
auto call(Args&&... args) -> decltype(invoke(types<Ret...>(), sizeof...(Args))) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user