lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Just an idea, but it might help if you show up some examples.

Take some code from your project - interface code and your scripts.
Write equivalent lua code and lua interface code (yep, that's quite some work).

Compare both. I would bet that lua wins this compare since it has really a great
API on integrating stuff and the lua syntax itself is really well designed.

Then take on and show what would be possible. Loading other modules. Integrate a
module that you downloaded from luaforge and show how easy it can be used in
your code (luasocket, luaexpat, luasql etc.), which can be be used quickly
without the need to write further code (since you will only write interface
code for your project).

Example: When we designed Luxinia, we took into account to write the netcode
facility in C. Turned out that with luasocket it's is way easier, more flexible
and not slower. I scrapped the C code on that without dropping a tear.
When we needed some XML imports, I grabbed luaexpat and could integrate a XML
parser for our project within a day. It's as simple as it could be and we can
concentrate on writing the stuff we want to write (3D /-physics stuff).

In my opinion, lua has a couple of advantages, but it has two key features that
beat most other languages, either because their implementation is just not as
good or they lack it totally:
- Coroutines - writing coroutine code is simple, straightforward and you don't
need any global variables for state information, keeps your code small and
- modularity - extend your running project with totally different modules that
are maintained as open source / 3rd party and load this during _runtime_

Eike Decker

Zitat von Tim Hunter <>:

> I have an opportunity to introduce Lua in my workplace. My goal is to 
> replace an existing scripting language. The existing language is 
> proprietary, was developed in-house, has limited functionality, is hard 
> to maintain and extend, and is only maintained by its inventor.
> I have already shown that Lua can be used in place of the existing 
> language, but my boss wants to know why we should bother. After all, he 
> says, the existing language is working (for now) and we have several 
> developers who are trained to use it. These developers would have to 
> learn Lua.
> Can you point me to existing web pages or other documentation that I can 
> use to help craft my rationale?
> Thanks!