Skip to content

Commit 8d0873c

Browse files
author
nitrocaster
committed
xrScriptEngine: Fix C4456 warnings.
1 parent 86bf661 commit 8d0873c

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

src/xrScriptEngine/Functor.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,17 @@ class functor : public adl::object
1616
template <typename... Args>
1717
TResult operator()(Args &&...args) const
1818
{
19-
auto self = static_cast<const adl::object *>(this);
20-
return call_function<TResult, policy_list<Policies...>>(*self, std::forward<Args>(args)...);
19+
auto obj = static_cast<const adl::object *>(this);
20+
return call_function<TResult, policy_list<Policies...>>(*obj, std::forward<Args>(args)...);
2121
}
2222
};
2323

2424
template <>
2525
template <typename... Args>
2626
void functor<void, typename...>::operator()(Args &&...args) const
2727
{
28-
auto self = static_cast<const adl::object *>(this);
29-
call_function<void, policy_list<Policies...>>(*self, std::forward<Args>(args)...);
28+
auto obj = static_cast<const adl::object *>(this);
29+
call_function<void, policy_list<Policies...>>(*obj, std::forward<Args>(args)...);
3030
}
3131

3232
namespace detail

src/xrScriptEngine/ScriptEngineScript.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@
1414
#include "Include/xrAPI/xrAPI.h"
1515
#include "ScriptExporter.hpp"
1616

17-
using namespace luabind;
18-
1917
void LuaLog(LPCSTR caMessage)
2018
{
2119
#ifndef MASTER_GOLD
@@ -151,6 +149,7 @@ std::ostream& operator<<(std::ostream& os, const profile_timer_script& pt)
151149

152150
SCRIPT_EXPORT(CScriptEngine, (),
153151
{
152+
using namespace luabind;
154153
module(luaState)
155154
[
156155
class_<profile_timer_script>("profile_timer")

0 commit comments

Comments
 (0)