内容如题目
lua代码如下:
file: test.lua
local c
c.a = 123
c代码如下:
file: test.c
#include <stdio.h>
#include "lua.h"
#include "lauxlib.h"
#include "lualib.h"
static int traceback( lua_State *L)
{
const char *msg = lua_tostring(L,-1);
if (msg)
{
/*打印发生错误时的堆栈信息,msg是错误信息,附加到打印的堆栈最前端
1是指从第一