Supratik Champati | 1 Jun 1999 17:12

Re: tolua limitation!!

Thanks for your response.

I tried what you suggested and get the same error.

struct vector
 {
   double coord[3];
 };

Error Message generated -
** tolua: parse error.

Code being processed:
double coord[3];

I am using the latest version 3.0 beta.
I have compiled on IRIX6.3 and HPUX-10.2.

Thanx.

Waldemar Celes wrote:
> 
> > When I try to use tolua on something like
> >
> > typedef struct vec_
> > {
> >     double coord[3];
> > } vector;
> >
> > I get a parse error on double coord[3].
(Continue reading)

Douglas Lee | 3 Jun 1999 12:57
Picon

free table

If I use lua_createtable() to creat a table, how should I free it while
it is no use any more ?

Thanks,
Douglas

Nick Trout | 3 Jun 1999 13:38
Picon

Speed comparison

Does anyone know how Lua compares in speed with other scripting languages.
eg. Python. ?

Is there any timing comparisons anywhere?

Cheers,
Nick

Picon

Re: Speed comparison

>From nick <at> videosystem.co.uk Thu Jun  3 09:07:49 1999

>Does anyone know how Lua compares in speed with other scripting languages.
>eg. Python. ?

Lua has been described as "the speed demon of scripting languages":
See http://www.hex.net/~cbbrowne/langscript.html:

  Lua is a scripting language developed in Brazil. It is apparently the
  "speed demon" of scripting languages (as compared to Python and Perl,
  and the nearly glacially slow TCL), and is fairly well suited to
  controlling graphical user interfaces.

>Is there any timing comparisons anywhere?

there are some in the SPE paper, and possibly some discussion about this
in the lua-l archive, but nothing extensive.
timing does seems to depend on the application.

--lhf

Supratik Champati | 3 Jun 1999 17:37

Re: Speed comparison

I have personally tested  lua, perl, python, tcl by writing
similar scripts. I found lua to be much faster (sorry cannot quantify
!!).
But the thing that really made me embrace lua is the sheer elegance
of the language.
Although relatively new, it is a very stable code.
The source code is still < 10k lines (compare with 60k+ lines for
perl/python).
I do not think going with lua can be a bad choice any which way one
looks at it.
But again this is just my opinion..

Supratik.

Nick Trout wrote:
> 
> Does anyone know how Lua compares in speed with other scripting languages.
> eg. Python. ?
> 
> Is there any timing comparisons anywhere?
> 
> Cheers,
> Nick

Bennett Todd | 3 Jun 1999 22:36

Re: Speed comparison

1999-06-03-15:44:38 Supratik Champati:
> I have personally tested lua, perl, python, tcl by writing similar scripts.
> I found lua to be much faster [...]

I'd expect that would depend strongly on what exactly you are doing. Many
things will be faster in perl, since many things can be done easily in perl
where the bulk of the actual work is being done by builtins (or by
dynamically-loaded extensions, written in C, that you've pulled down from
CPAN). As soon as you are doing substantial processing in the top-level
scripting language things slow down, and would expect they'd slow down less
for Lua than for most other languages.

> But the thing that really made me embrace lua is the sheer elegance
> of the language.
> Although relatively new, it is a very stable code.
> The source code is still < 10k lines (compare with 60k+ lines for
> perl/python).
> I do not think going with lua can be a bad choice any which way one
> looks at it.

I'd say it would depend on what you're doing.

For places where small is important, Lua is beautiful. For other jobs, where
size doesn't matter:-), I strongly prefer perl; it's so richly expressive,
there are so many high-level extensions available from CPAN, I can do so many
interesting chores with a minimum of code.

But I wouldn't want to e.g. fire up a perl for every local delivery of an
email message, whereas doing that with a Lua seems practical to me.

(Continue reading)

Freek Brysse | 4 Jun 1999 14:51
Picon

Re: Speed comparison

> 
> I have personally tested  lua, perl, python, tcl by writing
> similar scripts. I found lua to be much faster (sorry cannot quantify
> !!).
> But the thing that really made me embrace lua is the sheer elegance
> of the language.

Lua is great on almost every point, except the scoping rules. Why can't we
have normal scoping rules (i.e a variable is local unless defined
globally?).  Though I read the rationale behind that decision somewhere, I
wasn't exactly statisfied by it. 
Is there any who likes these scoping rules?

Are there any plans on changing this?

Freek B.

Douglas Lee | 4 Jun 1999 12:48
Picon

Re: Speed comparison

Yes, I like these scoping rules.

Freek Brysse wrote:

> >
> > I have personally tested  lua, perl, python, tcl by writing
> > similar scripts. I found lua to be much faster (sorry cannot
> quantify
> > !!).
> > But the thing that really made me embrace lua is the sheer elegance
> > of the language.
>
> Lua is great on almost every point, except the scoping rules. Why
> can't we
> have normal scoping rules (i.e a variable is local unless defined
> globally?).  Though I read the rationale behind that decision
> somewhere, I
> wasn't exactly statisfied by it.
> Is there any who likes these scoping rules?
>
> Are there any plans on changing this?
>
> Freek B.

Picon

An IDE for Lua

[I'm posting this on behalf of Pablo Saldo <ec4pas <at> super.furg.br because
 listproc choked on it --lhf]

>From: Pablo Saldo <ec4pas <at> super.furg.br>

Hi everybody,
I'm about to start my graduate project (I'm a computing engineering here in
Rio Grande, Brazil), and was thinking about developing an IDE for Lua. My
ideas are:
- a simple chunk editor, maybe with syntax highlight;
- a comand line, from where you'll be able to call de chunks, test some
commands and put them into the chunk;
- an objects repository, where you can manipulate the enviroment's objects;
- an object constructors repository; collection of functions explicitly
appointed as object constructors;

I'm looking for ideas on community's needs. of course it'd be using Lua. in
the principle, all the code would be construcuted in Lua, then some part of
it could be translated to C, for better performance. I'd like to now about
similar projects, references of essential aspects in concepting these
enviroment and, of course, Lua's designers perspectives for the new
versions of the language.

I'm waiting your colaboration,

Picon

Re: Speed comparison

>From freekb <at> igwe11.vub.ac.be Fri Jun  4 07:14:12 1999
>
>Lua is great on almost every point, except the scoping rules. Why can't we
>have normal scoping rules (i.e a variable is local unless defined
>globally?).  Though I read the rationale behind that decision somewhere, I
>wasn't exactly statisfied by it. 

there's a game you can play with the set/getglobal tag methods and with the
callhook so that global variables seem local to a chunk.

>Is there any who likes these scoping rules?

we do :-)

>Are there any plans on changing this?

sorry, no.
I don't think we're going to change anything in the syntax.
--lhf


Gmane