The Lua demo now has a nicer interface using Skywriter, and some additional bugfixes under the hood.
Check it out, and let me know if you find any problems!
Showing posts with label lua. Show all posts
Showing posts with label lua. Show all posts
Sunday, November 28, 2010
Friday, November 26, 2010
Lua Improvements
It seems there are people interested in running Lua on the web :) The Lua demo was on Hacker News, and some people noticed that certain things don't work - thanks for the feedback! - so I spent a few hours figuring out what was wrong. After some small fixes, the demo will now handle these statements:
The output seems ok, but I'm not totally sure that it's 100% correct, since my Lua skills are pretty rusty. That's also why I didn't notice the issues in the beginning - I saw that 'hello world' worked, and thought all was well ;)
If people really want to see this work properly, let me know about any other problems. I'm happy to work on it, I just can't do it without feedback since I don't know where to start testing. (Is there a standard test suite for Lua?)
The issues that had to be fixed in Emscripten were
- for k,v in pairs({'foo','bar'}) do print(k,v) end
- for x = 1,10 do print(x) end
- for k,v in pairs(_G) do print("->", k,v) end
The output seems ok, but I'm not totally sure that it's 100% correct, since my Lua skills are pretty rusty. That's also why I didn't notice the issues in the beginning - I saw that 'hello world' worked, and thought all was well ;)
If people really want to see this work properly, let me know about any other problems. I'm happy to work on it, I just can't do it without feedback since I don't know where to start testing. (Is there a standard test suite for Lua?)
The issues that had to be fixed in Emscripten were
- Lua uses varargs in ways that the existing code didn't support. So I improved that. Varargs are now emulated in a way that is basically identical to C.
- A few missing stdlib functions.
Subscribe to:
Posts (Atom)