loadResult = luaL_loadstring(L, myLuaProg_C); // load the text from a simple C lookup table
So far so good that all worked fine, but then I wanted to precompile myLuaProg.lua into bytecode before I ran it through the utility to convert it to a C lookup table source file.
To load the compiled program from the C lookup table I dont think I can use the luaL_loadstring() function, so I changed that to be
loadResult = luaL_loadbuffer (L, myLuaProg_C, sizeof(myLuaProg_C), "myProg"); // load the bytecode from a simple C lookup table
This didnt crash, it returns 0 OK, but the code does nothing. I am guessing I am misunderstanding this and using the wrong function here ?
Any thoughts would be appreciated. Thanks
Jeff