Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix incorrect deprecation hints
"good" and "bad" were swapped in the process, resulting in wrong deprecation messages
  • Loading branch information
SmallJoker committed Nov 1, 2020
1 parent 89dd05f commit 9c9344c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/script/lua_api/l_internal.h
Expand Up @@ -32,12 +32,12 @@ with this program; if not, write to the Free Software Foundation, Inc.,

#define luamethod_dep(class, good, bad) \
{#bad, [](lua_State *L) -> int { \
return l_deprecated_function(L, #bad, #good, &class::l_##good); \
return l_deprecated_function(L, #good, #bad, &class::l_##good); \
}}

#define luamethod_aliased(class, name, alias) \
luamethod(class, name), \
luamethod_dep(class, name, alias)
#define luamethod_aliased(class, good, bad) \
luamethod(class, good), \
luamethod_dep(class, good, bad)

#define API_FCT(name) registerFunction(L, #name, l_##name, top)

Expand Down

0 comments on commit 9c9344c

Please sign in to comment.