Hi Milind, > Actually I have selected Lua and my System user.lua has this line: path.lua = > 'C:/Program Files (x86)/Lua/5.1/lua.exe' so shouldn't it be using this > interpreter? It does use that interpreter, but only for execution, not compilation. If you want to skip compilation step completely, you can add "skipcompile = true" to the interpreter code and it will skip compilation step when you want to do Run/Debug (look at interpreters/gslshell.lua file for an example). > My pattern matching string is: "(.-)[\\\/]". I am creating a character set to > match the '\' or '/' slash. So I escape each of them with a back slash. How > should I change this for LuaJIT? Replace "\/" with "/". The list of allowed escapes is here: http://www.lua.org/pil/2.4.html. All the others will trigger the error you see in LuaJIT and in Lua 5.2. Paul. On Tue, Dec 24, 2013 at 2:47 PM, Milind Gupta <milind.gupta@xxxxxxxxx> wrote: > Hi Paul, > Thanks for the reply. Actually I have selected Lua and my System > user.lua has this line: path.lua = 'C:/Program Files (x86)/Lua/5.1/lua.exe' > so shouldn't it be using this interpreter? In the Project-> Lua interpreter > I have selected Lua. I also tried LuaForWindows, LuaJIT, Lua 5.2 but > everytime I get the compilation error due to that string. > My pattern matching string is: "(.-)[\\\/]". I am creating a character set > to match the '\' or '/' slash. So I escape each of them with a back slash. > How should I change this for LuaJIT? > > Thanks, > Milind > > > > On Tue, Dec 24, 2013 at 10:54 AM, Paul K <paul@xxxxxxxxxxxxx> wrote: >> >> Hi Milind, >> >> > I thought that zerobranestudio is using the command line lua >> > only? >> >> ZBS is using LuaJIT internally when it compiles Lua scripts before >> running them. LuaJIT is a bit more strict about string escapes than >> "plain" Lua. Just replace "\/" with "/" in your strings and your code >> will compile/run fine. >> >> Paul. >> >> On Mon, Dec 23, 2013 at 12:46 AM, Milind Gupta <milind.gupta@xxxxxxxxx> >> wrote: >> > Hi, >> > I have attached a script that complains about compilation error >> > when >> > I try to run from Zerobranestudio but if I execute it with lua from the >> > command line it runs fine! >> > I thought that zerobranestudio is using the command line lua >> > only? >> > Please can anybody help me figure out why I cannot compile on >> > zerobranestudio. Please try executing LuaTiddly.lua. The other 2 files >> > should be placed with LuaTiddly. >> > >> > Thanks, >> > Milind >> > >> >