diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2024-07-02 10:35:34 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2024-07-02 10:35:34 -0400 |
commit | 212868a8c3f803b387da602b6440f69c2c617e40 (patch) | |
tree | c8450709ea2f94b6a33ae4f305529bcac5d3fc69 /indra/newview | |
parent | ac56718929044e101dc2c7bfe3ebc5dff565b76d (diff) |
Promote LuaRemover from llluamanager.cpp to lua_function.h.
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llluamanager.cpp | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/indra/newview/llluamanager.cpp b/indra/newview/llluamanager.cpp index 77f197b2d2..c95ce9c57b 100644 --- a/indra/newview/llluamanager.cpp +++ b/indra/newview/llluamanager.cpp @@ -309,31 +309,6 @@ LLRequireResolver::LLRequireResolver(lua_State *L, const std::string& path) : luaL_argerrorL(L, 1, "cannot require a full path"); } -/** - * Remove a particular stack index on exit from enclosing scope. - * If you pass a negative index (meaning relative to the current stack top), - * converts to an absolute index. The point of LuaRemover is to remove the - * entry at the specified index regardless of subsequent pushes to the stack. - */ -class LuaRemover -{ -public: - LuaRemover(lua_State* L, int index): - mState(L), - mIndex(lua_absindex(L, index)) - {} - LuaRemover(const LuaRemover&) = delete; - LuaRemover& operator=(const LuaRemover&) = delete; - ~LuaRemover() - { - lua_remove(mState, mIndex); - } - -private: - lua_State* mState; - int mIndex; -}; - // push the loaded module or throw a Lua error void LLRequireResolver::findModule() { |