[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Why isn't Lua more widely used?
- From: Francesco Abbate <francesco.bbt@...>
- Date: Sat, 28 Jan 2012 17:53:28 +0100
2012/1/28 steve donovan <steve.j.donovan@gmail.com>:
> I suspect there's a backlash against dynamic languages for big
> application development because it's hard to catch typing errors and
> navigate big projects (explicit motivation given for the
> optionally-typed Dart language).
Absolutely, this is one the biggest issues when developing something
complex with a dynamic language like Lua or Python. Many small errors
that can be readily caught by a statically typed compiler does not
cause any warnings in Lua or Python. To make things worse add the
difficulty to spot the error at run time. In this case Python is even
worst than Lua because it does not have the "local" keyword and the
method to discriminate a global variables from a local one is a very
bad one.
This lack of ability to detect problems is in stark contrast with a
strongly typed programming language like OCaml where the compiler does
an amazing job detecting almost any type of errors during compilation.
I'm always dreaming of a Lua typed companion programming language. It
could be very similar to Lua, any language should be able to call
functions defined with the other transparently. The advantage would be
that the typed language would be better suited for complex
applications and could be also compiled to produce optimal code.
Francesco