update single

This commit is contained in:
ThePhD 2016-10-02 18:24:33 -04:00
parent 4ac35aa8f4
commit dd031613a8

View File

@ -20,8 +20,8 @@
// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// This file was generated with a script.
// Generated 2016-10-01 06:56:10.404062 UTC
// This header was generated with sol v2.14.8 (revision 72f39d8)
// Generated 2016-10-02 22:24:19.630150 UTC
// This header was generated with sol v2.14.8 (revision 4ac35aa)
// https://github.com/ThePhD/sol2
#ifndef SOL_SINGLE_INCLUDE_HPP
@ -4776,7 +4776,11 @@ namespace sol {
}
// Do advanced check for call-style userdata?
static const auto& callkey = name_of(meta_function::call);
lua_getmetatable(L, index);
if (lua_getmetatable(L, index) == 0) {
// No metatable, no __call key possible
handler(L, index, type::function, t);
return false;
}
if (lua_isnoneornil(L, -1)) {
lua_pop(L, 1);
handler(L, index, type::function, t);
@ -8761,7 +8765,7 @@ namespace sol {
}
template<typename T>
T get() const {
decltype(auto) get() const {
return tagged_get(types<meta::unqualified_t<T>>());
}
@ -9313,6 +9317,14 @@ namespace sol {
basic_object& operator=(base_t&& b) { base_t::operator=(std::move(b)); return *this; }
basic_object(const stack_reference& r) noexcept : basic_object(r.lua_state(), r.stack_index()) {}
basic_object(stack_reference&& r) noexcept : basic_object(r.lua_state(), r.stack_index()) {}
template <typename Super>
basic_object(const proxy_base<Super>& r) noexcept : basic_object(r.operator basic_object()) {}
template <typename Super>
basic_object(proxy_base<Super>&& r) noexcept : basic_object(r.operator basic_object()) {}
template <typename Super>
basic_object& operator=(const proxy_base<Super>& r) { this->operator=(r.operator basic_object()); return *this; }
template <typename Super>
basic_object& operator=(proxy_base<Super>&& r) { this->operator=(r.operator basic_object()); return *this; }
basic_object(lua_State* L, int index = -1) noexcept : base_t(L, index) {}
template <typename T, typename... Args>
basic_object(lua_State* L, in_place_type_t<T>, Args&&... args) noexcept : basic_object(std::integral_constant<bool, !std::is_base_of<stack_reference, base_t>::value>(), L, -stack::push<T>(L, std::forward<Args>(args)...)) {}