> If you're a member of this list, then you've *probably* downloaded the
> source code for AbiWord.
> 
> 
> Tcl
> --
> Pros
>        easy to embed
>        9 year history -- code base is mature and reasonably stable
>        built-in bindings to Tk
> Cons
>        ugly syntax
> Perl
> --
> Pros
>        doesn't matter, see the cons section
> Cons
>        hopelessly arcane, unreadable syntax
> 
> Python
> --
> Pros
>        readable
>        powerful language
>        multiple GUI toolkit bindings (ie stuff other than its Tk default)
> Cons
>        terrible name (we'd have to market it as AbiScript, or something
>                like that)
>        uses indenting to delimit blocks (aaack!)
>        no mindshare in our target market
> 
> Some of the stuff above is my opinion.  Some of it is the opinion our
> target market will have.  For example, personally, I rather like Perl,
> but its syntax is patently absurd for a target market which includes
> people like my Dad, or people like the VB crowd.

Well, personally, I think you are trying to 'put yourself in the heads of other
people' - which is always a dangerous occupation. To figure out what is the 
easiest for other people to use, I always try to modularate the current 
popularity of the language and correlate it against how much 'marketing' that
language has had. For the four above:

1) JavaScript - very popular, lots of marketing.
2) Tcl        - popular, not that much marketing. (but backing from Sun)
3) Perl       - popular, not that much marketing.
4) Python     - not very popular, not that much marketing.

In the four you list above, you dismiss one of the most popular (perl) and list 
'ugly syntax' as cons against two of the most popular (tcl and perl). In fact
you dismiss one of them simply *because* of its ugly syntax. But if 
'ugly syntax' was a reasoning that people made in choosing a language, well,
python would be a lot more popular than perl and tcl, wouldn't it?


Now, what does it mean to have an 'ugly syntax'?  At first blush, tcl and perl
have a more 'ugly syntax' because they use special characters, but believe me,
programming in python gets *real old* when you delimit blocks via tabs. When
I tried python, I ended up *emulating* brackets to delimit blocks.

Blecch. This in itself takes half of the power away from any editor more 
powerful than 'notepad', and makes my job ten times as difficult in tracking
down bugs. In fact, this was my personal choice in deciding away from python. 

Anyways, does it really make *any* difference whether or not you stick a '$' in 
front of variables? In other words, is:

    AoA = [ [1,2,3], [10,11,12], [4,5,6], [7,8,9] ];
    AoA.sort( lambda a, b: b[-1] - a[-1] );

any more readable than:

    @AoA = ( [1,2,3], [10,11,12], [4,5,6],  [7,8,9] );
    @AoA = sort { $a->[-1] <=> $b->[-1] } @AoA; 

I don't think so; sure there are a couple of special characters in the front
of '@AoA' - but all that does is to serve to notify me that I'm dealing with
an *array*. Without the semantic clues, you can get lost in python a lot easier
than you can perl or tcl.

Hence, you should (IMO) base your decision on how much *power* the language has
and how much unsolicited popularity it has, not on an aesthetic judgement of 
how the language looks.  IMO, JavaScript is fair to poor in terms of both use 
*and* power. Python is sort of powerful, but also is pretty unknown (the 
O'Reilly book is the only one I know about on the language).

I would therefore (if I was making the choice) choose either tcl or perl. 
Tcl is easier to embed, but perl is more powerful, so its really a toss up.

Ed

Reply via email to