On Tue, 25 Oct 2005, Stevan Little wrote:
Well, the point is that it is interesting to note that "text processing"
is an _application area_, whereas "OO programming" is a programming
language paradigm.
Allow me to clarify.
Perl 5 (and below) are known by outsiders (non-perl users) as being a really
good language for processing text. Ask any friend you know who has had little
or no exposure to Perl and they will probably tell you this. Of course they
will also tell you that it is all line noise, etc, etc etc. This is the most
common perception of Perl by those people who have (for the most part) never
encountered it.
ack!
I think that Perl 6 may become like that for OO. When people who have never
used or encountered Perl 6 talk about it, they will say, "I've never used it,
but I hear it has lots of really cool OO features". Just as now they the same
thing re: text-processing.
I see your point. And I admit I slightly misunderstood you. In any case
people who don't know Perl and think it's great for text processing may be
eventually become interested in it if they will have to do... ehm... text
processing.
But even if Perl will gain a name for it's "cool OO features", will it
become an actual interest for someone if he/she has to do... OO stuff?!?
The basic idea being that one is attracted by a language or another if its
features are well suited for some specific application he/she has in mind.
Not for its features as an abstract thing.
Also, Perl6 OO capabilities are already above the top of my head. But
maybe that's just me. Whatever, I guess that the {casual,average}
programmer may be scared by its richness and complexity.
After all, being known for text processing capabilities may be somewhat
restictive and not faithful of Perl's (including Perl 5) full
potentiality,
Of course not, Perl is also used for CGI, but you can do that better with
Java now (which is a real language cause it's compiled)
Of Perl is IMHO even _too_ known for CGI.
but "OO programming" is somewhat immaterial either, the "only" relevance
being the suitability for big projects management.
The idea that OO is only relevant for big projects is just as silly as saying
that Perl is only good for text processing.
ack. I was oversimplifying.
Sure I would not use OO to write a small utility script, but the modules I
access in the script would probably be written using OO. And those may be
very small modules too, but their re-usability is greatly enhanced by various
OO features (encapsulation, ability to compose-into or use within another
class, etc etc etc). This kind of thing (IMHO) is why so many people are
being drawn to Python and Ruby. Hopefully Perl 6 can draw them back.
Also, some methods will be very handy even for non-patently-OO blocks,
e.g. the .pos() one which will replace the somewhat ad hoc pos() function
or the .subst() one (or whatever it is called, I can't remember exactly)
which hopefully will get rid of the "why doesn't s/// work inside a map()"
question...
Michele
--
Have you ever stopped to consider that what is crashing
your Perl is sitting between the keyboard and chair?
- Sherm Pendley in clpmisc, "Re: Perl IDE" (edited)