lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hi guys,

I was trying to use the lua_getstack and lua_getinfo(...,"Sln",...) to get
debug infos and print a call stack trace but it doesn't seem to get all the
right informations for some reason... the currentline, linedefined,
lastlinedefined work just fine but the "source" field always contains the
entire file and the short_src the "whatever" characters on the first line
(also "name" sometimes contains some weird characters).

I am using a vanilla version of lua integrated in my C++ project, creating a
new state with lua_newstate, using luaL_openlibs right after it and running
the code with luaL_loadstring using a zero terminated text source plus a
separate lua_pcall to run the script.

I have also tried printing the trace using the debug module straight in lua
but i have the same issue with source/short_src.

Any thoughts?
I will really appreciate any help.

Thank you



--
View this message in context: http://lua.2524044.n2.nabble.com/lua-Debug-issue-with-source-and-short-src-tp7653895.html
Sent from the Lua-l mailing list archive at Nabble.com.