lua_pushnill(L); while(lua_next(L, -2)) { //这时值在-1(栈顶)处,key在-2处。 lua_pop(L, 1);//把栈顶的值移出栈,让key成为栈顶以便继续遍历 }.
確定! 回上一頁