[11088] in Perl-Users-Digest
Perl-Users Digest, Issue: 4689 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jan 19 13:05:21 1999
Date: Tue, 19 Jan 99 10:01:29 -0800
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Tue, 19 Jan 1999 Volume: 8 Number: 4689
Today's topics:
Re: Perl Criticism topmind@technologist.com
Re: Perl Criticism topmind@technologist.com
Re: Perl Criticism topmind@technologist.com
Re: Perl Criticism topmind@technologist.com
Re: Perl Criticism <staffan@ngb.se>
Re: Perl Criticism <dgris@moiraine.dimensional.com>
Re: Perl Criticism <staffan@ngb.se>
Re: Perl Criticism (I R A Aggie)
Re: Perl Criticism <staffan@ngb.se>
Re: Perl Criticism <staffan@ngb.se>
Re: Perl Criticism (Richard Clamp)
Re: Perl Criticism topmind@technologist.com
Re: port scanning <cheezz@rhein.to>
problem with a script running on iis/nt <derrienn@bruyeres.cea.fr>
problem with: use module; <jtane@etu.info.unicaen.fr>
Re: problem with: use module; <aidan@salvador.blackstar.co.uk>
Special: Digest Administrivia (Last modified: 12 Dec 98 (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 19 Jan 1999 16:50:45 GMT
From: topmind@technologist.com
Subject: Re: Perl Criticism
Message-Id: <782d4v$72j$1@nnrp1.dejanews.com>
In article <36A3788E.2D6B3F79@pbi.net>,
Troy Terry <tterry@pbi.net> wrote:
> Andrew Johnson wrote:
> >
> > [cross quoted from several postings]
> >
> > topmind wrote:
> > ! code and realize that the system is composed of 30,000 lines
> > ! of code that looks something like this:
> > !
> > !
> > ! perl -le
> > '$n=170;for($d=2;($d*$d)<=$n;$d+=(1+($d%2))){for($t=0;($n%$d)==0;
> > ! $t++){$n=int($n/$d);}while($t-->0){push(@r,$d);}}if($n>1){push(@r,$n);}
> [...]
>
> Gracious!
>
> Reminds me of a scene I witnessed once:
> PROGRAMMER: Geez, look at this 2000-line "if" statement!
> MANAGER: That's why it didn't work!
> MANAGER'S MANAGER: If I ever see code like that again,
> [Turns to PROGRAMMER] you're fired. [Turns to MANAGER]
> And so are you!
>
> [... Discussion of funky code sample...]
> >
> > ! > It's called a code-review... But you won't care so why am I
> > bothering.
> > !
> > !
> > ! Few companies actually spend the money or time for such.
> > ! I am not against it, but just saying that it will not
> > ! occure very often, just like training.
> >
> > ok, so you want to blame a language for the hiring practices of
> > some company?
>
> It is likely that topmind is overstating his case, but there is
> an interesting assumption in his argument; that is, that the
> tools you use -- in this case programming language -- have a
> large effect on the work you put out. If this is true, then
> his claim that perl needs to be 'fixed' or replaced deserves
> some consideration.
>
> The question becomes then, what kind of mindset or programming
> practices does perl encourage? Does it encourage any bad ones?
>
> I would be willing to accept that each language has functionality
> which is easy to implement in that language. (I'd rather use C
> than gw-basic to implement a linked-list scheme) I'm not sure that
> I believe topmind's larger claim, that perl encourages hard-to-read
> code.
>
But I see Perl code that tries to do what are really "table-oriented"
operations. It can be done in Perl with enough operations,
but it is hard for me to believe that table-orientedness is
Perl's strength.
BTW, I never have to use linked lists in table-oriented languages.
Tables do that stuff for me and a lot safer.
> Perhaps wiser heads than mine have some ideas.
>
> Yours,
> T. Terry
>
-Tmind- (T=table)
http://www.geocities.com/SiliconValley/Lab/6888/
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
------------------------------
Date: Tue, 19 Jan 1999 16:43:51 GMT
From: topmind@technologist.com
Subject: Re: Perl Criticism
Message-Id: <782co4$6k0$1@nnrp1.dejanews.com>
In article <s61187.93d.ln@magna.metronet.com>,
tadmc@metronet.com (Tad McClellan) wrote:
> Tad McClellan (tadmc@metronet.com) wrote:
> : : In article <77terh$um$1@nnrp1.dejanews.com>,
> : : topmind@technologist.com wrote:
>
> : : > It must be that I am reaching celebrity
> : : > status in this group
>
> : Don't be getting all puffed up about celebrity status.
Awwww, can't I pretend?
>
> : Daffy Duck is a celebrity...
And probably a Perl programmer with variables with
names like:
ththththaaaattzzit = thththfileoppzen(<ffffilehandle>,"name.ththat")
>
> Oh yeah.
>
> There was some other celebrity I wanted to see mentioned
> in this thread...
>
> ... now who was that...
>
> ... (scratch head)...
>
> Oh! Now I remember...
>
> ... Adolph Hitler is a celebrity!
>
> And with that, this thread is now free to ride off into
> the sunset.
Hitler rode off into a dug hole, not a sunset.
Hmmm, Hitler and Daffy in the same message.
There has to be a joke in their somewhere.
Duck step? Naaaaa.
>
> --
> Tad McClellan SGML Consulting
> tadmc@metronet.com Perl programming
> Fort Worth, Texas
>
-tmind-
http://www.geocities.com/SiliconValley/Lab/6888/
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
------------------------------
Date: Tue, 19 Jan 1999 16:55:55 GMT
From: topmind@technologist.com
Subject: Re: Perl Criticism
Message-Id: <782dek$790$1@nnrp1.dejanews.com>
In article <36A372C1.D74CD228@atrieva.com>,
Jerome O'Neil <jeromeo@atrieva.com> wrote:
> Staffan Liljas wrote:
> >
> > topmind@technologist.com wrote:
> > > I have not seen it in Perl, but in almost every other system
> > > that I was a followup person for. I truely doubt Perlers are
> > > immune or better tought readibility skills. It is obvious
> > > that they where only interested in finishing and don't care
> > > about maintainability costs (they don't pay 'em).
>
The last sentence was taken out of context. It is refering to
bad programmers in general, not just Perlers.
> > I would strongly suggest interpreting what you just said into a sign
> > that perl-programmers write more maintainable and readable code than
> > other programmers do. But maybe there is some nuance of your use of the
> > English language that is eluding me. I'm a Swede, you know.
>
> This has been my contention for some time. Perl makes it *easier* to
> write maintainable code due to it's linguistic background. I have a QA
> department to which I like to submit my code for review before I place
> it on-line. These guys don't know a whole lot of perl, but it is
> readable enough to get good feedback from them.
What exactly is special about Perl or Perlers that makes Perl
*more* readable? I have seen nothing yet to set Perl apart.
>
> --
> Jerome O'Neil, Operations and Information Services
> Atrieva Corporation, 600 University St., Ste. 911, Seattle, WA 98101
> jeromeo@atrieva.com - Voice:206/749-2947
> The Atrieva Service: Safe and Easy Online Backup http://www.atrieva.com
>
-tmind-
http://www.geocities.com/SiliconValley/Lab/6888/langopts.htm
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
------------------------------
Date: Tue, 19 Jan 1999 17:00:43 GMT
From: topmind@technologist.com
Subject: Re: Perl Criticism
Message-Id: <782dnk$7l0$1@nnrp1.dejanews.com>
In article <slrn7a5hj4.dj5.sholden@pgrad.cs.usyd.edu.au>,
sholden@cs.usyd.edu.au wrote:
> On Sat, 16 Jan 1999 20:52:56 GMT, topmind@technologist.com wrote:
> >In article <77l7kc$8mj$1@nnrp1.dejanews.com>,
> > tiptopmind@my-dejanews.com wrote:
> >
> >Why are some of you trying to slam me personally?
> >
> >Fortunately, I am perfectly able to defend my opinions
> >and enjoy debates, but only from PEOPLE WHO LOOK
> >AT THE IDEA INSTEAD OF TRYING TO SLANDER SOMEBODY
> >PERSONALLY.
> >
> >It is a shame that sick people like you roam the
> >web. I bet you are a professional spammer or hack
> >for living. How many credit cards number have you
> >stolen you sick creap! Sick intentions from
> >sick people.
>
> How do you manage to type those last two paragraphs without spontaneously
> combusting in a display of contradiction that chakes the universe???
> >
> >
> >> In article <77hgnn$1u2$1@nnrp1.dejanews.com>,
> >> topmind@technologist.com wrote:
> >>
> >> >GO TO HELL YOU SICK, LYING CREEP!!!!!!!!!
>
> Oh you said that as well... I think you might have started this 'SLANDER'
> thing that you complain about. I could be wrong, the message could have
> been edited, I don't care enough to actually take the time to check back
> and see...
Some fool is collecting other non-technical links that I have
done and trying to use them to embarass or discredit me.
I find it sick and twisted motivation to do such a thing.
What the h*ll is going through a mind like that?
-pissedmind-
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
------------------------------
Date: Tue, 19 Jan 1999 18:18:03 +0100
From: Staffan Liljas <staffan@ngb.se>
Subject: Re: Perl Criticism
Message-Id: <36A4BE4B.79D8E206@ngb.se>
topmind@technologist.com wrote:
> ththththaaaattzzit = thththfileoppzen(<ffffilehandle>,"name.ththat")
Interesting. This is the first piece of perl code we see from topmind.
I'm not surprised he's mad at perl. WHY DOESN'T THIS WORK???
Staffan
------------------------------
Date: 19 Jan 1999 10:46:07 -0700
From: Daniel Grisinger <dgris@moiraine.dimensional.com>
Subject: Re: Perl Criticism
Message-Id: <m3vhi32m1s.fsf@moiraine.dimensional.com>
[I wasn't going to reply to this thread anymore, but couldn't
help myself]
topmind@technologist.com writes:
> Come on now. I switch between dozens of languages.
Dozens? Really? I think that you are lying, please list them.
Include code samples (ability to write `hello, world' does not
count as knowing a language).
The reason that I don't believe you is that all of your criticisms
are in line with what I would expect from someone with minimal
fluency in one language who is trying to acquire a second.
> Am I the only one with this problem?
I believe so.
> Do you all use only one
> language and/or always keep them strait?
I regularly program in C, Java, Python, Lisp, Perl, and C++. I have
no difficulty keeping everything straight. In addition, I have been
playing recently with Intercal and Prolog and am planning on playing
with Smalltalk as soon as I get some free time (yeah, right :-).
> (I am sure a few
> do keep them strait, but don't exprapolate your greatness
> in such a narrow area to everybody else.)
Ability to use your tools is not a sign of greatness. I think that it
is reasonable to expect _programmers_ to know how to use programming
languages. That you find it difficult is more a reflection of your
mental inadequacy than anything else.
dgris
--
Daniel Grisinger dgris@moiraine.dimensional.com
perl -Mre=eval -e'$_=shift;;@[=split//;;$,=qq;\n;;;print
m;(.{$-}(?{$-++}));,q;;while$-<=@[;;' 'Just Another Perl Hacker'
------------------------------
Date: Tue, 19 Jan 1999 18:45:07 +0100
From: Staffan Liljas <staffan@ngb.se>
Subject: Re: Perl Criticism
Message-Id: <36A4C4A3.79F0EA81@ngb.se>
topmind@technologist.com wrote:
> But I see Perl code that tries to do what are really "table-oriented"
> operations. It can be done in Perl with enough operations,
> but it is hard for me to believe that table-orientedness is
> Perl's strength.
No, maybe not. But I don't think that this is perls fault, if indeed it
is a fault. I assume Visual Objects would be considered table-oriented,
and in observing what it really does, with its database servers etc,
when looking behind the scenes, it's all done with objects and
inheritance. And this could clearly be done in perl too. However, maybe
noone has wanted to create the corresponding objects in perl. Why, may
one ask? Maybe because perl-programmers prefer not using xbase
databases, which is the basis of at least Visual Objects, and several
other TOPs. Why is this? I think the reason is that perl-programmers in
general prefer to work with SQL.
Now you may ask: Why isn't there any dataservers in perl for SQL
databases, as there is in, for example, Visual Objects? The reason, if
you ask me, is that SQL and other so called relational databas models
don't lend themselves well to database server objects of this type.
Instead you use session objects etc, which, in fact, makes more sense.
Staffan
------------------------------
Date: Tue, 19 Jan 1999 12:38:47 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: Perl Criticism
Message-Id: <fl_aggie-1901991238470001@aggie.coaps.fsu.edu>
In article <782dek$790$1@nnrp1.dejanews.com>, topmind@technologist.com wrote:
+ What exactly is special about Perl or Perlers that makes Perl
+ *more* readable? I have seen nothing yet to set Perl apart.
Because we can be as verbose as we like? because we can embed the
documentation into the program, and extract that information via
perldoc?
Sure, I could do, say:
$a=1;
$b=2;
$c=3;
But I can do that in C, too. Or Fortran. Or Pascal. Or Ada. Or pretty much
in any language you care to name.
James
------------------------------
Date: Tue, 19 Jan 1999 18:49:10 +0100
From: Staffan Liljas <staffan@ngb.se>
Subject: Re: Perl Criticism
Message-Id: <36A4C596.4AE0125D@ngb.se>
topmind@technologist.com wrote:
> Come on now. I switch between dozens of languages. Every now and
> then I put Java in VB and visa versa. Without certain restrictions,
> it may just run, but be interpreted as a boolean or something
> unintended.
>
> Am I the only one with this problem? Do you all use only one
> language and/or always keep them strait? (I am sure a few
> do keep them strait, but don't exprapolate your greatness
> in such a narrow area to everybody else.)
No but perl warns you.
Staffan
------------------------------
Date: Tue, 19 Jan 1999 18:47:54 +0100
From: Staffan Liljas <staffan@ngb.se>
Subject: Re: Perl Criticism
Message-Id: <36A4C54A.5C285C@ngb.se>
topmind@technologist.com wrote:
> Some fool is collecting other non-technical links that I have
> done and trying to use them to embarass or discredit me.
> I find it sick and twisted motivation to do such a thing.
> What the h*ll is going through a mind like that?
When publishing information publicly, ie on the web, one has to count on
that anyone can find that information. That's kind of the general idea
of publishing them. Try NOT to publish embarrasing information, or use a
way of hiding your identity that the people who might see the
information can't see through.
Staffan
------------------------------
Date: Tue, 19 Jan 1999 17:51:15 GMT
From: richardc@tw2.com (Richard Clamp)
Subject: Re: Perl Criticism
Message-Id: <36a4c0de.56708275@news.highwayone.net>
On Tue, 19 Jan 1999 16:55:55 GMT, topmind@technologist.com wrote:
>What exactly is special about Perl or Perlers that makes Perl
>*more* readable? I have seen nothing yet to set Perl apart.
At the risk of being obtuse, you're probably not looking carefully
enough, or maybe you're looking too hard.
Since you're not finding it by looking at Perl you probably need to
look at the other vector, Perl programmers.
In my personal experience most[1] programmers who use Perl are
experienced, seasoned hackers who use Perl as a matter of preference
and whould be churning out readable code in whichever language they
were using[2] as a matter of pride.
Now of course you'll get bad programmers, and if they were in a
newspeak-style language which prevented bad ideas they might be safe,
but I doubt it.
I guess my point is, you just have to be selective about your
programmers, if they're bad then avoid them, don't wrap all of them in
bubble-wrap, only the kinky ones will enjoy it.
Richard
[1] excluding that shady group calling themselves Perl Mongers :)
[2] excluding of course VBScript ASP, but then you have to be
sympathetic in some cases
--
Richard Clamp
richardc@tw2.com
London.pm's brummie mascot
------------------------------
Date: Tue, 19 Jan 1999 17:06:12 GMT
From: topmind@technologist.com
Subject: Re: Perl Criticism
Message-Id: <782e1q$7sn$1@nnrp1.dejanews.com>
In article <slrn7a5hcr.dj5.sholden@pgrad.cs.usyd.edu.au>,
sholden@cs.usyd.edu.au wrote:
> On Sat, 16 Jan 1999 20:46:38 GMT, topmind@technologist.com wrote:
> >In article <slrn79se7t.lmc.dformosa@godzilla.zeta.org.au>,
> > dformosa@zeta.org.au (David Formosa (aka ? the Platypus)) wrote:
> >> In article <77kusq$kh$1@nnrp1.dejanews.com>, droby@copyright.com wrote:
> >> >In article <slrn79lm8o.mtj.dformosa@godzilla.zeta.org.au>,
> >> > dformosa@zeta.org.au (David Formosa (aka ? the Platypus)) wrote:
> >>
> >> [...]
> >>
> >> >> Then have your boolean equility operator called "eq" then.
> >
> >
> >I guess this could be considered, but it is a bit harder to
> >read than the symbols and less familiar. I shall put it in
> >the next revision, okay?
> >
> >(I can't find the original message for this.)
> >
> >> >>
> >> >
> >> >Or get an APL keyboard and use left-arrow for assignment. Or emulate
Algol
> >> >and use := for assignment.
> >>
> >
> >
> >But people who use a lot of languages will keep forgetting
> >the ":" and accidently make them booleans.
>
> Of course people will also mistype 'eq' as '=' so there really is no
> solution if you assume that the programmer is a complete and utter
> moron as you assume to.
>
Come on now. I switch between dozens of languages. Every now and
then I put Java in VB and visa versa. Without certain restrictions,
it may just run, but be interpreted as a boolean or something
unintended.
Am I the only one with this problem? Do you all use only one
language and/or always keep them strait? (I am sure a few
do keep them strait, but don't exprapolate your greatness
in such a narrow area to everybody else.)
> --
> Sam
>
> You are bordering on ridiculous if you think you need to support your
> premises. Such an argument is an infinite regression.
> --George Reese in <wv0O1.1521$Ge.4809664@ptah.visi.com>
>
-tmind-
http://www.geocities.com/SiliconValley/Lab/6888/langopts.htm
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
------------------------------
Date: Tue, 19 Jan 1999 17:02:47 +0100
From: "Cheezz" <cheezz@rhein.to>
Subject: Re: port scanning
Message-Id: <7829qd$m6g$1@usenet42.supernews.com>
well I put in yahoo.com and it won't work...
Thanks
Willem <spam@dikkelul.com> wrote in message
news:780dc0$b9n$1@dinkel.civ.utwente.nl...
>use IO::Socket;
>$addr = "dikkelul.com";
>$port = "80";
>$prot = "tcp";
>$r = IO::Socket::INET->new(Proto=>$prot,PeerAddr=>$addr,PeerPort=>$port);
>$remote ? (print "Connected!\n") : (die "Error, couldn't connect!\n");
>
>good luck
>Willem
>
>
------------------------------
Date: Tue, 19 Jan 1999 16:10:13 +0100
From: Marc Derriennic <derrienn@bruyeres.cea.fr>
Subject: problem with a script running on iis/nt
Message-Id: <36A4A055.79E88CF3@bruyeres.cea.fr>
hy,
(sorry for my poor English...)
here is th pb
I wrote a perl script that must be called in a form through a CGI
in a MSDOS Window the script runs perfectly
When it is called from a web browser it doesn't work
I'm trying to obtain the listing of a directory but the pipe is refused,
the command line is :
open (TAB,"dir D:\\wwwroot\\form /b |");
I recieve an error "Access Refused" that doesn't appear if I remove the
"|"
of course then the command doesn't work !!!
what can I do ?
thx
Marc
--
o------------------------------------------------o
| Marc DERRIENNIC |
| \|/ derrienn@bruyeres.cea.fr |
| @ @ http://www.multimania.com/spoon |
o-oOO-(_)-OOo------------------------------------o
------------------------------
Date: Tue, 19 Jan 1999 16:40:16 +0100
From: Julien 'Jay' Tane <jtane@etu.info.unicaen.fr>
Subject: problem with: use module;
Message-Id: <36A4A760.93550F0@etu.info.unicaen.fr>
Hello,
I have a problem with use module;
It all works fine with the library from perl.
But it doesn't work with the modules that are in directory where the
main script is.
In the main file: mainfile.pl I have: use Module;
and in a file called "Module.pm" I have:
package Module;
sub pretrait {
...
}
when I try : perl mainfile.pl
it stops the compilation and prints:
Module.pm did not return a true value at mainfile.pl
BEGIN failed-- compilation aborted at mainfile.pl line 13
I have tried to use a BEGIN, witha require and export. (even using
exporter).
And I have tried also to add to @INC the path to the module.pm,
and it seems to me it worked ( that is the path was added); but nothing
changed.
And I a not the only one to whom that happened.
Thanks for wour answers
Jay
------------------------------
Date: 19 Jan 1999 16:38:37 GMT
From: Aidan Rogers <aidan@salvador.blackstar.co.uk>
Subject: Re: problem with: use module;
Message-Id: <782ced$bt$1@nclient3-gui.server.ntli.net>
<snip>
> it stops the compilation and prints:
> Module.pm did not return a true value at mainfile.pl
> BEGIN failed-- compilation aborted at mainfile.pl line 13
Every module in Perl has to return a true value. Put in the following line
at the end of your code and it should work.
1;
And that's it!
Aidan
------------------------------
Date: 12 Dec 98 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Special: Digest Administrivia (Last modified: 12 Dec 98)
Message-Id: <null>
Administrivia:
Well, after 6 months, here's the answer to the quiz: what do we do about
comp.lang.perl.moderated. Answer: nothing.
]From: Russ Allbery <rra@stanford.edu>
]Date: 21 Sep 1998 19:53:43 -0700
]Subject: comp.lang.perl.moderated available via e-mail
]
]It is possible to subscribe to comp.lang.perl.moderated as a mailing list.
]To do so, send mail to majordomo@eyrie.org with "subscribe clpm" in the
]body. Majordomo will then send you instructions on how to confirm your
]subscription. This is provided as a general service for those people who
]cannot receive the newsgroup for whatever reason or who just prefer to
]receive messages via e-mail.
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.
The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V8 Issue 4689
**************************************