Ignore:
Timestamp:
03/08/16 13:19:59 (9 years ago)
Author:
epyon
Message:
  • temporary Lua 5.1 hardcode
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lua/lua_state.cc

    r486 r490  
    6767void nv::lua::state_wrapper::push_global_table()
    6868{
    69         lua_pushglobaltable( m_state );
     69        nlua_pushglobaltable( m_state );
    7070}
    7171
     
    173173nv::size_t lua::table_guard::get_size()
    174174{
    175         return lua_rawlen( m_state, -1 );
     175        return nlua_rawlen( m_state, -1 );
    176176}
    177177
     
    272272{
    273273        lua_getfield( m_state, -1, element.data() );
    274         char result = ( lua_type( m_state, -1 ) == LUA_TSTRING && lua_rawlen( m_state, -1 ) > 0 ) ? lua_tostring( m_state, -1 )[0] : defval;
     274        char result = ( lua_type( m_state, -1 ) == LUA_TSTRING && nlua_rawlen( m_state, -1 ) > 0 ) ? lua_tostring( m_state, -1 )[0] : defval;
    275275        lua_pop( m_state, 1 );
    276276        return result;
     
    288288{
    289289        lua_getfield( m_state, -1, element.data() );
    290         unsigned result = lua_type( m_state, -1 ) == LUA_TNUMBER ? lua_tounsigned( m_state, -1 ) : defval;
     290        unsigned result = lua_type( m_state, -1 ) == LUA_TNUMBER ? nlua_tounsigned( m_state, -1 ) : defval;
    291291        lua_pop( m_state, 1 );
    292292        return result;
     
    364364
    365365        lua_pushcfunction(m_state, luaopen_base);
    366         lua_pushliteral(m_state, LUA_TABLIBNAME);
     366        lua_pushliteral(m_state, "");
    367367        lua_call(m_state, 1, 0);
    368368
     
    524524void lua::state::deep_pointer_copy( int index, void* obj )
    525525{
    526         index = lua_absindex( m_state, index );
     526        index = nlua_absindex( m_state, index );
    527527        lua_newtable( m_state );
    528528        lua_pushnil( m_state );
Note: See TracChangeset for help on using the changeset viewer.