Lua/LuaInstance: Add move constructor/operator

Former-commit-id: 8d5b28036983597b7b0fc324aa3795d25a9719b8 [formerly f4b8d4e3a69c0af27d909d9efd75b6480ab10126] [formerly f4574b549cc7645cdabb6d2aacb630090648753c [formerly 3ea26bacc97d0e3bd3ca69aabd29f243d07fb869]]
Former-commit-id: 40f99457abbf7ed6a24760c2e62e3750d7866315 [formerly 6b881febbb5a07ab25b3e5e3580f9b8717a454d7]
Former-commit-id: a5d8a7c3f8731c4dd9d3b059ebf04cd1598dacc7
This commit is contained in:
Lynix
2016-08-28 19:03:43 +02:00
parent c1835575c6
commit 303fe658cf
2 changed files with 29 additions and 2 deletions

View File

@@ -31,7 +31,7 @@ namespace Nz
public:
LuaInstance();
LuaInstance(const LuaInstance&) = delete;
LuaInstance(LuaInstance&&) = delete; ///TODO
inline LuaInstance(LuaInstance&& instance) noexcept;
~LuaInstance();
void ArgCheck(bool condition, unsigned int argNum, const char* error);
@@ -172,7 +172,7 @@ namespace Nz
void* ToUserdata(int index, const String& tname) const;
LuaInstance& operator=(const LuaInstance&) = delete;
LuaInstance& operator=(LuaInstance&&) = delete; ///TODO
inline LuaInstance& operator=(LuaInstance&& instance) noexcept;
static int GetIndexOfUpValue(int upValue);
static LuaInstance* GetInstance(lua_State* state);