But is it just me, or does it seem like Lua never generates any buzz in the media? In the major tech news aggregators (at least the ones that I typically check) its always Javascript this, or Ruby that, or Python everything.
Yet when you look at what Lua's actually done and been used for in the industry it certainly seems disproportionate to the eerie silence it seems to experience in the blogosphere. Just for example I'm going to drop a few names now of commercial products which use Lua: Eyeon Digital Fusion, Adobe Photoshop Lightroom, Sim City 4, World of Warcraft, Warhammer Online, Escape from Monkey Island, Psychonauts, and this is just a handful, if you want to see a couple of exhaustive lists then I'm sure Google and Wikipedia can help you.
Anyway I'm not trying to raise a stink, I just think its an interesting question to ask because Lua is a real world language being used by serious mainstream projects yet you hardly hear a blip about it, and I have no idea why.
I can think of only one thing which has happened in the Lua world fairly recently which was caught and discussed on the web and that was Google giving a Lua developer an $8k donation to work on the amd64 port of the Lua-jit.
I just happened to hear this morning of a new Lua project AiMa-Lua which will be implementing the code from "Aritificial Inteligence, a Modern Approach" by Stuart Russell and Peter Norvig as an example of good Lua coding for practice. I always like these types of projects, and I look forward to seeing the result.
In my opinion a better book couldn't have been chosen, it is essentially "the" book when it comes to this subject. I own a 1st edition copy and it weighs in at over 800 pages.
While it is expensive its one of the few books I'd say are actually worth owning simply for having such a reputable monster sitting on your shelf.
You can pick up your own copy of the behemothic Artificial Intelligence: A Modern Approach (3rd Edition)
17 replies:
Having tinkered with writing WoW addons in Lua, I was interested to see if there was an actively developed lua web framework. I must admit that I was a bit surprised to find that no such initiative really exists, particularly given what a nice language it is.
kit: You mean something like http://www.keplerproject.org/ ?
For most programmers, Lua has all the unfamiliarity of JavaScript's object system with none of the familiarity of syntax. I mean, seriously, 1-base arrays?
Lua is a great language that is small and efficient and designed primarily for embedded use. In order to compete with Perl/Python/Ruby, it would need a general set of libraries and, preferably, an extensibility mechanism similar to Perl's CPAN. This is something the authors have specifically avoided. It is easy to start adding things to a language, but then it becomes big and bloated, which is counter to their original aims. It would be nice to see a set of libraries evolve (beyond the core libraries) that could be used in a dynamic fashion. This way we would get the best of both worlds.
@openid: Lua's entire grammar fits in less than a single page. It's easy to pick up.
I agree about the object system; it's definitely got that roll-your-own aspect to it which can make it challenging to collaborate.
I'm speculating here, but 1-based arrays seem to be a by-product of "we need in-band error codes in C" and "we're supporting lots of sometimes strange architectures." Does anybody know anything about this decision?
toddlucas have it right: all those companies don't program in Lua, they script their existing programs in it. On that terrain real competitors are probably javascript and scheme.
I think it's in part because Lua first became big in the game industry, which is not known for its openness and is still dominated by the large players. Many game companies guard their IP religiously, and often the developers are under NDAs. You won't see them organize a friendly neighbourhood somethingCamp to share and learn.
On the web, where Python, Ruby and JS got popular, most of the value lies in putting together a good product and getting a community around it. The tech IP isn't really that important unless you're Google. Hence, lots of small start ups try to differentiate themselves with openness, and put a lot of effort into outreach.
I agree that one of the reasons is the secrecy in the game industry. But I think another reason why nobody talks about Lua is that its developers live "far away" (in Brazil). Ruby, the only other "big" language developed outside the US, only got the news in 2006, with Ruby on Rails, which was developed in the US.
It is much harder to evangelize from far away.
I wonder if it has anything to do with Lua's simplicity. The lack of a thick wad of standard library (coupled with the extreme ease of extending the Lua environment with one's own functionality) mean that once you've learned the basics of Lua the language and Lua the interpreter, there's very little else to know. If a subject is too simple, there's little buzz to generate in talking about it.
It's heartbreaking to think that there may be such a thing as "minimum complextiy" required to get people talking about a development tool.
Nobody talks about it because it's not used for web apps or for general purpose programming. It is used primarily as an embedding language which it excels at. Ruby and Python suck for embedding (I have experience embedded all three into different forms of applications commercial and non-commercial). Nice amazon referral plug, do you really deserve any traffic or referral clicks for providing no amount of substance though?
Part of it might simply be people's perception of it as a simple language for embedding within larger applications. This has obviously been where it has excelled. The problem then is that it is difficult to see how a language meant for the masses (WoW players aren't necessarily aiming for computer science greatness as much as wanting more gold).
This is just a thought really. I've never tired Lua in depth, but personally I assumed that since it is primarily a scripting tool for things like games, it would not be something powerful enough with libraries and the like to more extensive work with.
you can even use Lua to develop Iphone app. See: http://www.anscamobile.com/corona/
I just built my first site written in LUA, it was fun and works. Tucents.net
an earlier comment said lua was primarily designed for embedded use. this is not true. it wasn't designed for embedded use. it was designed for general use, just like python, perl, ruby, etc. but it turns out that lua is quite well suited for embedded use, for many reasons.
And I thought Norvig was a Python addicted...now he's also a Lua coder :)
Good for him. And good for Lua !
A general-purpose langauge should include lots of libs for most common tasks. (Python is an example, Java and C are others).
Since lua is only a minimal feature set it has the best portability as an embedded language. And the best embedded language is not the best general-purpose language.
It is not a very good general-purpose language so it will not be talked about in generic programmers, but for programmers need an embedded language, more than 90% programmers know lua.
They know, they talk.
I stumbled across your post while looking for some Lua information. I don't have a good answer to why Lua doesn't get more attention; but I thought you might enjoy this video of a "Why Lua" talk I gave last month:
http://kylecordes.com/2010/lua-strange-loop
Post a Comment