Changeset 540 for trunk/src/lua/lua_proxy.cc
- Timestamp:
- 01/25/17 20:20:45 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lua/lua_proxy.cc
r539 r540 9 9 #include "nv/lua/lua_raw.hh" 10 10 #include "nv/lua/lua_state.hh" 11 #include "nv/lua/lua_types.hh" 11 12 12 13 using namespace nv; … … 58 59 } 59 60 61 bool nv::lua::stack_proxy::is_valid() const 62 { 63 return !( lua_isnil( *m_state, m_index ) ); 64 } 65 66 bool nv::lua::stack_proxy::read( const type_entry* entry, void* object ) const 67 { 68 NV_ASSERT_ALWAYS( m_state->get_type_data()->get_type_database() == entry->type_db, "Type database mismatch between Lua and entry!" ); 69 if ( lua_type( *m_state, m_index ) != LUA_TTABLE ) return false; 70 return nv::lua::read_rtti_type( m_state, entry, object, m_index ); 71 } 72 60 73 bool nv::lua::stack_proxy::is_table() const 61 74 {
Note: See TracChangeset
for help on using the changeset viewer.