Skip to content

Commit

Permalink
Merge pull request #52 from zhangjiequan/feat/extend_all_lua_types_fo…
Browse files Browse the repository at this point in the history
…r_pr

Replace hard-coded LUA_TTHREAD+1 with LUA_NUMTAGS macro to improve readability
  • Loading branch information
CppCXY committed Feb 20, 2024
2 parents 61d8cb5 + 93193a5 commit 2d76b15
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions emmy_debugger/include/emmy_debugger/api/lua_api_loader.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@ typedef ptrdiff_t lua_KContext;
#define LUA_TUSERDATA 7
#define LUA_TTHREAD 8

#define LUA_NUMTAGS 9


/*
** Type for C functions registered with Lua
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,5 +143,5 @@ class Debugger: public std::enable_shared_from_this<Debugger>

Arena<Variable> *arenaRef;

std::bitset<LUA_TTHREAD+1> registeredTypes;
std::bitset<LUA_NUMTAGS> registeredTypes;
};

0 comments on commit 2d76b15

Please sign in to comment.