CheckType -> CheckLuaObjectType

This commit is contained in:
Glenn Maynard
2005-06-23 08:46:21 +00:00
parent be8c5d23b5
commit 36794f6d5f
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -19,7 +19,7 @@ void CreateMethodsTable( lua_State *L, const CString &szName )
* Get a userdata, and check that it's either szType or a type * Get a userdata, and check that it's either szType or a type
* derived from szType, by walking the __index chain. * derived from szType, by walking the __index chain.
*/ */
bool CheckType( lua_State *L, int narg, const char *szType ) bool CheckLuaObjectType( lua_State *L, int narg, const char *szType )
{ {
int iTop = lua_gettop(L); int iTop = lua_gettop(L);
lua_pushvalue( L, narg ); lua_pushvalue( L, narg );
+2 -2
View File
@@ -6,7 +6,7 @@
#include "LuaManager.h" #include "LuaManager.h"
void CreateMethodsTable( lua_State *L, const CString &szName ); void CreateMethodsTable( lua_State *L, const CString &szName );
bool CheckType( lua_State *L, int narg, const char *szType ); bool CheckLuaObjectType( lua_State *L, int narg, const char *szType );
template <typename Type> template <typename Type>
class Luna class Luna
@@ -95,7 +95,7 @@ public:
// get userdata from Lua stack and return pointer to T object // get userdata from Lua stack and return pointer to T object
static T *check( lua_State *L, int narg, bool bIsSelf = false ) static T *check( lua_State *L, int narg, bool bIsSelf = false )
{ {
if( !CheckType(L, narg, m_sClassName) ) if( !CheckLuaObjectType(L, narg, m_sClassName) )
{ {
if( bIsSelf ) if( bIsSelf )
luaL_typerror( L, narg, m_sClassName ); luaL_typerror( L, narg, m_sClassName );