🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.misc
Article #2920

Re: Which to use :- Perl, Python, Icon, ... ?

#2920
From: Peter da Silva
Date: Thu, 07 Mar 1991 15:52
54 lines
3015 bytes
In article <BEVAN.91Mar5123224@tiger.cs.man.ac.uk> bevan@cs.man.ac.uk (Stephen J Bevan) writes:
> As this is a bit of nightmare as regards maintenance, I'd
> like to move to a single language for doing these sort of tasks.  The
> likely contenders for this seem to be Perl, Python and Icon.

You should probably consider TCL as well. I'm not familiar with Python
and only have a reading-the-manuals acquaintance with Perl and a bit more
with Icon. Icon is certainly the most "real" language, in terms of having a
consistent design, of any of these. TCL has the advantage that it is almost
trivial to extend it with C code, and merge it with existing C applications.
So...

>   + Does the language have any arbitrary limits? e.g. the length of a
>     line ... etc.

No.

>   + How fast is it?  This can be compared to whatever you like, but each
>     other preferably.  I'm not really interested if XXX is only, X%
>     quicker than YYY on average (whatever that maybe).

Well, we replaced some shell scripts with TCL scripts here and got on the
order of a factor of a hundred speedup. So I'd say it's "fast enough". I
suspect that the other languages you're considering are on the same order of
magnitude. 

>   + Does it give `reasonable' error messages?  i.e. something better
>     than the equivalent of `awk bailing out on line X'.

You can get a complete call trace of the error if that's your thing.

>   + Does it have a debugger?  If not, are there any extra facilities
>     for debuggging above and beyond simply inserting `printf' (change
>     as appropriate) statements.

You can trace code execution on a statement by statement basis. You can also
redefine "proc" to put whatever code wrappers you want around procedures,
and redefine any of the functions in the language similarly.

>   + Does it allow conditional interpretation/compilation? i.e.
>     anything like +FEATURE in Lisp or #ifdef FEATURE/#endif in C.

Yes, since it simply executes the input file you can put a proc inside
an if with no problem.

>   + The fact that Perl has a C like syntax is NOT an advantage in my
>     book.  (I'm not saying its a disadvantage either, I just don't
>     think it's important either way).

TCL is like a text-oriented Lisp, but lets you write algebraic expressions
for simplicity and to avoid scaring people away.
-- 
Peter da Silva.  `-_-'  peter@ferranti.com
+1 713 274 5180.  'U`  "Have you hugged your wolf today?"
Technical Details
Message-ID: <=GY9XYF@xds13.ferranti.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!lavaca.uh.edu!menudo.uh.edu!sugar!ficc!peter
References: <BEVAN.91Mar5123224@tiger.cs.man.ac.uk>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!lavaca.uh.edu!menudo.uh.edu!sugar!ficc!peter
From: peter@ficc.ferranti.com (Peter da Silva)
Newsgroups: comp.lang.misc
Subject: Re: Which to use :- Perl, Python, Icon, ... ?
Message-ID: <=GY9XYF@xds13.ferranti.com>
Date: 7 Mar 91 15:52:29 GMT
References: <BEVAN.91Mar5123224@tiger.cs.man.ac.uk>
Reply-To: peter@ficc.ferranti.com (Peter da Silva)
Distribution: comp
Organization: Xenix Support, FICC
Lines: 54