| 1809 | template <typename T> |
| 1810 | template <typename Function> |
| 1811 | void LuaMethods<T>::registerMethod(String name, Function&& func) { |
| 1812 | if (!m_methods.insert(name, LuaDetail::wrapMethod(std::forward<Function>(std::move(func)))).second) |
| 1813 | throw LuaException::format("Lua method '{}' was registered twice", name); |
| 1814 | } |
| 1815 | |
| 1816 | template <typename T> |
| 1817 | template <typename Return, typename... Args, typename Function> |