Home Download Buy Blog Forum Support

Cannot Build Lua Script

Cannot Build Lua Script

Postby ani.khan on Mon Sep 24, 2012 7:31 pm

The following for-loop throws a syntax error in Sublime 2:

Code: Select all
for i = 1,3 do print(i) end

File "/Users/.../test.lua", line 1
for i = 1,3 do print(i) end
SyntaxError: invalid syntax
[Finished in 0.0s with exit code 1]

But it executes fine in Terminal:

> for i = 1,3 do print(i) end

Please advise. I am new to Lua, but don't see that this syntax has changed over the last few versions of Lua. How can one tell what version of a language is supported? And how do I get my code to build? Thanks so much in advance.
Posts: 1
Joined: Mon Sep 24, 2012 7:21 pm

Return to Technical Support

Who is online

Users browsing this forum: Google [Bot] and 7 guests