[8527] in Perl-Users-Digest
Perl-Users Digest, Issue: 2144 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Mar 20 12:07:23 1998
Date: Fri, 20 Mar 98 09:00:30 -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 Fri, 20 Mar 1998 Volume: 8 Number: 2144
Today's topics:
Re: CGI script failing...asking for hint re: error msg <barnett@houston.Geco-Prakla.slb.com>
Re: compiling perl <indy@NOSPAMdemobuilder.com>
Re: dis gotta be a easy one?!?!?! (Joe McMahon)
Re: Dynamically checking for existing functions (I R A Aggie)
Re: Dynamically checking for existing functions <jdporter@min.net>
HELP! strange problem with loop <lsj@bnl.gov>
Re: HELP! strange problem with loop <uri@sysarch.com>
Re: HELP! strange problem with loop (Mike Stok)
How can I lock a tied hash? hhernand@autrey.com
How to take the icecream from the trashbox? <rossen@hikari-jhs.yamaguchi-u.ac.jp>
Re: How to take the icecream from the trashbox? <jdf@pobox.com>
NT <browns1@borg.com>
Re: NT <jdf@pobox.com>
Re: NT <jdporter@min.net>
Re: Perl Daemons (Richard Bellavance)
Re: perl script won't work as cgi (Craig Berry)
Re: Perl5 equivalent to freopen (Andrew M. Langmead)
Re: Question about DBM Array [FAQ perlrun] (Mike Stok)
Question about DBM Array lihong@public1.guangzhou.gd.cn
Re: Stinking lousy $*(@#*$@ cmd lin args-HELP (Richard Bellavance)
Re: Storing and sorting numerical keys <jdf@pobox.com>
Re: Storing and sorting numerical keys (Rich Morin)
Re: Strange: die $object un-blesses the object?? (Jason Gloudon)
Re: Wanted: email address gleaner <jp@glpbooks.BADMAIL.com>
Re: Wanted: Perl for Windows 3.x (Richard Bellavance)
Re: what is wrong with being a novice ?? (Jason Gloudon)
Re: what is wrong with being a novice ?? (I R A Aggie)
Re: what is wrong with being a novice ?? (John Klassa)
Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 20 Mar 1998 09:21:35 -0600
From: Dave Barnett <barnett@houston.Geco-Prakla.slb.com>
Subject: Re: CGI script failing...asking for hint re: error msg
Message-Id: <3512897F.E6C08D0E@houston.Geco-Prakla.slb.com>
Alex Lane wrote:
>
> I have a RedHat Linux 4.2 box set up and am trying to run a cgi script
> written in Perl.
>
> An attempt is apparently being made to execute the script, but the
> following appears in the error_log file:
>
> exec of <script name and path> failed, errno is 2
> <date/time> access to <script name and path> failed for <user>, reason:
> Premature end of script headers.
>
Without looking at your code, since you didn't post any, my assumption
is that you don't have a proper html header as the first thing you
output.
Include
print "Content-type: text/html\n\n";
as the first line of output.
Note: 2, yes 2, newlines are required.
> Might someone be able to shed some light on what's wrong here? Thanks in
> advance.
>
<snip>
HTH.
Dave
--
"Security through obscurity is no security at all."
-comp.lang.perl.misc newsgroup posting
------------------------------------------------------------------------
* Dave Barnett U.S.: barnett@houston.Geco-Prakla.slb.com *
* DAPD Software Support Eng U.K.: barnett@gatwick.Geco-Prakla.slb.com *
------------------------------------------------------------------------
------------------------------
Date: Fri, 20 Mar 1998 10:17:32 -0500
From: "Indy Singh" <indy@NOSPAMdemobuilder.com>
Subject: Re: compiling perl
Message-Id: <6eu194$ca7$1@nntp2.uunet.ca>
Matthew MacGibbon wrote in message <3510178C.5F0F@corp.airmedia.com>...
>I remember a while back someone had come up with something that allowed
>you to create an executable from a perl script. Does anyone know
>anything about that? (or a perl 2 c converter?)
Check out http://www.demobuilder.com/perl2exe.htm
------------------------------
Date: 20 Mar 1998 16:20:12 GMT
From: joe.mcmahon@gsfc.nasa.gov (Joe McMahon)
Subject: Re: dis gotta be a easy one?!?!?!
Message-Id: <joe.mcmahon-2003981124530001@prtims.stx.com>
In article <3511FD11.34B1@ix.netcom.com>, hld <hldpub@ix.netcom.com> wrote:
>hi,
>How do you excute a ./filename.cgi to test for syntax errors
> if you don't have a shell account or telenet access.
> Have cgi bin thru FTP only.
> Got cute ftp pro
> Got wsftp
>
>theres gotta be another way...is there?????
>
Install Perl on your machine. Since you used CGI.pm to develop your program,
you can run it under perl -d, input the CGI parameters on STDIN, and then
step through the program.
You DID use CGI.pm, right? If not, I strongly suggest you consider it.
Simpler, easier, and better. Being able to run your program from the
command line and enter the CGI parameters (that's right, no webserver
needed) is a big win.
--- Joe M.
------------------------------
Date: Fri, 20 Mar 1998 10:21:18 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: Dynamically checking for existing functions
Message-Id: <fl_aggie-2003981021180001@aggie.coaps.fsu.edu>
In article <3514479e.30744543@news.tornado.be>, bart.mediamind@tornado.be
(Bart Lateur) wrote:
+ But why does
+
+ print \&James;
+
+ print something like "CODE(0x153b14)", even though sub James was not
+ defined?
I am a complete entity. I am not a subroutine!
James -- :) as necessary
--
Consulting Minister for Consultants, DNRC
The Bill of Rights is paid in Responsibilities - Jean McGuire
To cure your perl CGI problems, please look at:
<url:http://www.perl.com/CPAN-local/doc/FAQs/cgi/idiots-guide.html>
------------------------------
Date: Fri, 20 Mar 1998 10:04:59 -0500
From: John Porter <jdporter@min.net>
Subject: Re: Dynamically checking for existing functions
Message-Id: <3512859B.313A@min.net>
Andrew M. Langmead wrote:
>
> bart.mediamind@tornado.be (Bart Lateur) writes:
>
> >"defined \&coder" would have made more sense, I think. But why does
> > print \&James;
> >print something like "CODE(0x153b14)", even though sub James was not
> >defined?
>
> Weird. At first I thought it was some sort of autovivication, but it
> doesn't exist afterward.
Not so weird. You asked for a reference, and you got a reference.
If you ask for a reference to an (undefined) sub, you get a
reference to an undefined sub.
A term like
&doit
is just an entry in a symbol table after all, just like
$val
Would you expect a reference to a scalar to be undefined
just because the scalar was undefined?
John Porter
------------------------------
Date: Fri, 20 Mar 1998 10:01:11 -0500
From: "Lance" <lsj@bnl.gov>
Subject: HELP! strange problem with loop
Message-Id: <6eu0bq$k91$1@sun20.ccd.bnl.gov>
Hi,
I have a strange problem, well, maybe a dumb one.
I'm trying to use a loop like this:
#!/usr/local/bin/perl -w
$var3=1.9; # line A
while ($var3 >= 0) {
print "\$var3=$var3\n";
if ($var3 <= 0.1) { # line B
print "plonk x1=$var3\n"; # line C
}
$var3 = $var3 - 0.2;
}
If I use this program, line C is not printed, which means
it doesn't go into the IF block. Whereas I simply change
line A into $var3=0.9, and line C is printed! Or if I change
line B to if ($var3 le 0.1), line C is printed as well(no matter
what value is assigned to $var3 in line A)!
Is this some kind of bug or there's something basic that I'm
missing? Any advice will be appreciated!
--
Regards,
Lance J.
------------------------------
Date: 20 Mar 1998 11:24:08 -0500
From: Uri Guttman <uri@sysarch.com>
To: lsj@bnl.gov
Subject: Re: HELP! strange problem with loop
Message-Id: <x790q5ib4n.fsf@sysarch.com>
"Lance" <lsj@bnl.gov> writes:
> Hi,
> I have a strange problem, well, maybe a dumb one.
> I'm trying to use a loop like this:
>
> #!/usr/local/bin/perl -w
> $var3=1.9; # line A
> while ($var3 >= 0) {
> print "\$var3=$var3\n";
> if ($var3 <= 0.1) { # line B
> print "plonk x1=$var3\n"; # line C
> }
> $var3 = $var3 - 0.2;
> }
>
> If I use this program, line C is not printed, which means
> it doesn't go into the IF block. Whereas I simply change
> line A into $var3=0.9, and line C is printed! Or if I change
> line B to if ($var3 le 0.1), line C is printed as well(no matter
> what value is assigned to $var3 in line A)!
>
> Is this some kind of bug or there's something basic that I'm
> missing? Any advice will be appreciated!
yes, a good email reply address!!
also a fundamental understanding of floating point math on a computer.
try replacing the firest print with this:
printf "\$var3=%.20f\n", $var3;
and it might give you a clue.
uri
--
Uri Guttman ----------------- SYStems ARCHitecture and Software Engineering
Perl Hacker for Hire ---- 8 Years of Perl Experience, Available Immediately
uri@sysarch.com --------- Resume and Perl Example at http://www.sysarch.com
Use the Best Search Engine on the Net -------- http://www.northernlight.com
------------------------------
Date: 20 Mar 1998 16:49:10 GMT
From: mike@stok.co.uk (Mike Stok)
Subject: Re: HELP! strange problem with loop
Message-Id: <6eu6m6$c7q@news-central.tiac.net>
In article <6eu0bq$k91$1@sun20.ccd.bnl.gov>, Lance <change AT into @> wrote:
>Hi,
> I have a strange problem, well, maybe a dumb one.
> I'm trying to use a loop like this:
>
>#!/usr/local/bin/perl -w
>$var3=1.9; # line A
>while ($var3 >= 0) {
> print "\$var3=$var3\n";
> if ($var3 <= 0.1) { # line B
> print "plonk x1=$var3\n"; # line C
> }
> $var3 = $var3 - 0.2;
>}
>Is this some kind of bug or there's something basic that I'm
>missing? Any advice will be appreciated!
You're experiencing an effect of using a binary representation of real
numbers, try this:
#!/usr/local/bin/perl -w
for ($var3 = 1.9; $var3 >= 0; $var3 -= 0.2) {
printf "\$var3 = %.20f\n", $var3;
if ($var3 <= 0.1) {
print "plonk x1=$var3\n";
}
}
and you should see that floating point arithmetic is not always exact. My
lasy line is:
$var3 = 0.10000000000000020000
Section 4 of the FAQ has a related question and answer:
Why am I getting long decimals (eg, 19.9499999999999) instead of the
numbers I should be getting (eg, 19.95)?
Internally, your computer represents floating-point numbers in binary.
Floating-point numbers read in from a file, or appearing as literals in
your program, are converted from their decimal floating-point
representation (eg, 19.95) to the internal binary representation.
However, 19.95 can't be precisely represented as a binary floating-point
number, just like 1/3 can't be exactly represented as a decimal floating-
point number. The computer's binary representation of 19.95, therefore,
isn't exactly 19.95.
When a floating-point number gets printed, the binary floating-point
representation is converted back to decimal. These decimal numbers are
displayed in either the format you specify with printf(), or the current
output format for numbers (see the section on $# in the perlvar manpage if
you use print. $# has a different default value in Perl5 than it did in
Perl4. Changing $# yourself is deprecated.
This affects all computer languages that represent decimal floating-point
numbers in binary, not just Perl. Perl provides arbitrary-precision
decimal numbers with the Math::BigFloat module (part of the standard Perl
distribution), but mathematical operations are consequently slower.
To get rid of the superfluous digits, just use a format (eg, printf("%.2f",
19.95)) to get the required precision.
If you want to be safe you have to allow for a small margin of error
(epsilon) in floating point calculations, in my /usr/include/float.h I
find
#define DBL_EPSILON 2.2204460492503131e-16
so it might make sense to redo the code as:
#!/usr/local/bin/perl -w
use POSIX ':float_h';
for ($var3 = 1.9; $var3 >= 0; $var3 -= 0.2) {
print "\$var3=$var3\n";
if ($var3 <= (0.1 + DBL_EPSILON)) {
print "plonk x1=$var3\n";
}
}
Hope this helps,
Mike
--
mike@stok.co.uk | The "`Stok' disclaimers" apply.
http://www.stok.co.uk/~mike/ | PGP fingerprint FE 56 4D 7D 42 1A 4A 9C
http://www.tiac.net/users/stok/ | 65 F3 3F 1D 27 22 B7 41
stok@colltech.com | Collective Technologies (work)
------------------------------
Date: Fri, 20 Mar 1998 09:57:16 -0600
From: hhernand@autrey.com
Subject: How can I lock a tied hash?
Message-Id: <6eu3gt$ahs$1@nnrp1.dejanews.com>
What is right way to lock a tied hash?
I made a program that updates a dbm file.
It works using a tied hash on the file. However I am
concerned about two users updating the file at the same time.
Can I lock the tied hash before changing it and then unlock it.
>From what I have seen I can use the flock() function but
I need a file handle to do it. How do I get the file handle?
Should I get a file handle for the index file or the data file?
--
Thank you
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/ Now offering spam-free web-based newsreading
------------------------------
Date: Fri, 20 Mar 1998 23:02:23 +0900
From: Rossen Mikhov <rossen@hikari-jhs.yamaguchi-u.ac.jp>
Subject: How to take the icecream from the trashbox?
Message-Id: <351276EF.305F3D56@hikari-jhs.yamaguchi-u.ac.jp>
Hello. I have a problem and I would very much appreciate an advice.
I have a long string and I want to get only a part of it. This is my
script
#Start
$trashbox =":trash:trash:chocolate-icecream:arrow:trash:trash:trash";
#The location of the icecream is just behind the ':arrow'
$icecream_only = #What?
#End
Thanks in advance.
Rossen.
------------------------------
Date: 20 Mar 1998 10:28:24 -0500
From: Jonathan Feinberg <jdf@pobox.com>
Subject: Re: How to take the icecream from the trashbox?
Message-Id: <ra3xtm93.fsf@news.concentric.net>
Rossen Mikhov <rossen@hikari-jhs.yamaguchi-u.ac.jp> writes:
> I have a long string and I want to get only a part of it.
I'm guessing that you haven't yet read the book _Learning Perl_, which
is really the place to begin if you're going to be doing any perl
programming. Also, perl comes with a very rich set of documentation
that you'll want to get comfortable with. But _Learning Perl_, or
some paid training, is the way to go for now. Then, if you have some
specific trouble with your code, we'll be better able to help you in
this newsgroup. Good luck.
--
Jonathan Feinberg jdf@pobox.com Sunny Brooklyn, NY
------------------------------
Date: Fri, 20 Mar 1998 09:44:24 -0500
From: Vinnie <browns1@borg.com>
Subject: NT
Message-Id: <351280C8.A595A6DA@borg.com>
We are running NT4.0 server on our machine. Where can I get a verision
of Pearl.exe that will run on my machine?
Vinnie Salerno
------------------------------
Date: 20 Mar 1998 10:25:26 -0500
From: Jonathan Feinberg <jdf@pobox.com>
Subject: Re: NT
Message-Id: <soodtme1.fsf@news.concentric.net>
Vinnie <browns1@borg.com> writes:
> Where can I get a verision of Pearl.exe that will run on my machine?
^^^^^
What's funny is that my mind went "Peh-ahrl... what the hell is
peh-ahrl?"
Try http://www.perl.com/ .
--
Jonathan Feinberg jdf@pobox.com Sunny Brooklyn, NY
------------------------------
Date: Fri, 20 Mar 1998 10:34:10 -0500
From: John Porter <jdporter@min.net>
Subject: Re: NT
Message-Id: <35128C72.2571@min.net>
Vinnie wrote:
>
> We are running NT4.0 server on our machine. Where can I get a verision
> of Pearl.exe that will run on my machine?
Did you try searching for "pearl.exe" on Yahoo?
John Porter
------------------------------
Date: 20 Mar 1998 10:01:10 -0500
From: charlot@CAM.ORG (Richard Bellavance)
Subject: Re: Perl Daemons
Message-Id: <6eu0bm$rtj@ocean.CAM.ORG>
In article <3512b4b6.5060646@news.mindspring.com>,
Mark Kucera <kucera@mindsrping.com> wrote:
>this does help, but you still need something to invoke the script that
>invokes the script yes?? i am going to see if i can find info about
>making perl compile to native code, and using the os (unix based) to
>try to schedule the daemon hopefully that will do some good
>
Depending on your exact needs, you could use one of:
- a crontab entry
- /etc/inittab
- a startup script (in /etc/rc*.d)
You don't have to compile your script for any of those. Just make sure your
script is executable and that the "#!" line points to the Perl interpreter.
Richard.
--
Richard Bellavance -- charlot@cam.org -- http://www.cam.org/~charlot/
"All along this path I tread / My heart betrays my weary head
With nothing but my love to save / From the cradle to the grave"
(Eric Clapton, "From the cradle")
------------------------------
Date: 19 Mar 1998 21:15:19 GMT
From: cberry@cinenet.net (Craig Berry)
Subject: Re: perl script won't work as cgi
Message-Id: <6es1t7$ai8$1@marina.cinenet.net>
Brian Charles (brian.charles@orst.edu) wrote:
: Why won't this PERL script work as a CGI script. It runs fine at the
: command prompt but not over the web.
This isn't a Perl question, but rather a CGI or web hosting question.
I'm not being difficult or trying to cause you problems; this *really
truly* has nothing to do with Perl.
: Any suggestions?
Ask on a CGI or web-hosting newsgroup.
: (PS cgi newsgroups has some problems, that's why I post here)
Yes, problems like inappropriate posts. :) Seriously, what does this
mean?
BTW, just because I'm in a good mood...a quick glance seems to indicate
that you never emit a content type line in your script. Again, this is a
CGI issue, not a Perl issue. Best of luck!
---------------------------------------------------------------------
| Craig Berry - cberry@cinenet.net
--*-- Home Page: http://www.cinenet.net/users/cberry/home.html
| Member of The HTML Writers Guild: http://www.hwg.org/
"Every man and every woman is a star."
------------------------------
Date: Fri, 20 Mar 1998 14:58:21 GMT
From: aml@world.std.com (Andrew M. Langmead)
Subject: Re: Perl5 equivalent to freopen
Message-Id: <Eq4HLA.CJ1@world.std.com>
Phil Hutchinson <philh@asptech.com> writes:
>I'd like to redirect STDOUT and STDERR to a disk file and the following
>successfully doesn't work.
You're thinking C-ishly, and perl's filehandle redirection syntax
comes more from its shellish heritage. (vaguely)
If you take a look at the section on open() in the perlfunc man page,
you will see that you use the ">&" symbol to dup a filehandle. The
corresponding example shows saving STDOUT and STDERR, redirecting it
to a file, and restoring it.
--
Andrew Langmead
------------------------------
Date: 20 Mar 1998 16:51:15 GMT
From: mike@stok.co.uk (Mike Stok)
Subject: Re: Question about DBM Array [FAQ perlrun]
Message-Id: <6eu6q3$c7q@news-central.tiac.net>
In article <6eu3pi$b0c$1@nnrp1.dejanews.com>,
<lihong@public1.guangzhou.gd.cn> wrote:
>I am using my workstation Perl. Is there any way to
>know the version of perl. (not like perl5 which is stated
>in the first line of script#!/usr/local/bin/perl5), the
>first line in my script should be /usr/local/bin/perl.
>so what's its version?
perl -v
or
perl -V
should give you information about perl's version. Thecommandl line flags
for perl are documented in the perlrun manual page.
Hope this helps,
Mike
--
mike@stok.co.uk | The "`Stok' disclaimers" apply.
http://www.stok.co.uk/~mike/ | PGP fingerprint FE 56 4D 7D 42 1A 4A 9C
http://www.tiac.net/users/stok/ | 65 F3 3F 1D 27 22 B7 41
stok@colltech.com | Collective Technologies (work)
------------------------------
Date: Fri, 20 Mar 1998 09:59:54 -0600
From: lihong@public1.guangzhou.gd.cn
Subject: Question about DBM Array
Message-Id: <6eu3pi$b0c$1@nnrp1.dejanews.com>
I am using my workstation Perl. Is there any way to
know the version of perl. (not like perl5 which is stated
in the first line of script#!/usr/local/bin/perl5), the
first line in my script should be /usr/local/bin/perl.
so what's its version?
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/ Now offering spam-free web-based newsreading
------------------------------
Date: 20 Mar 1998 09:45:53 -0500
From: charlot@CAM.ORG (Richard Bellavance)
Subject: Re: Stinking lousy $*(@#*$@ cmd lin args-HELP
Message-Id: <6etvf1$rcv@ocean.CAM.ORG>
In article <6es594$fqs@camel20.mindspring.com>,
rickryan@ Mindspring <rickryan@mindspring.com> wrote:
>I'm trying to capture a command line argument from within a perl script. I
>realize it's not rocket science and I've spent the whole day searching for
>the answer. Here's what I'm doing: (on yea, it's running on an NT server)
>
In Perl, command-line arguments are in the array @ARGV. But read on...
>(this is typed in from the browser's address prompt)
>
So it's not a "command-line argument" !!! It's a CGI argument ! I think
you should go to http://www.cgi-resources.com/ and look at the documentation
available there... There's a fine section on programming CGI in Perl.
Richard.
--
Richard Bellavance -- charlot@cam.org -- http://www.cam.org/~charlot/
"All along this path I tread / My heart betrays my weary head
With nothing but my love to save / From the cradle to the grave"
(Eric Clapton, "From the cradle")
------------------------------
Date: 20 Mar 1998 10:12:04 -0500
From: Jonathan Feinberg <jdf@pobox.com>
Subject: Re: Storing and sorting numerical keys
Message-Id: <u38ttn0b.fsf@news.concentric.net>
David Reilly <reilly@ozy.dec.com> writes:
> I want to store information (a line of text), using as my key a
> numberical number (hh:mm:ss)
As an aside, that's not a number.
> 00:00:00 line of text
> 00:05:01 another line
> 00:00:00 second line of text
One idea is to hang a list off of each key. You'll find such
techniques in the perldata, perlref, perllol, and perldsc documents.
#!/usr/bin/perl -w
while(<DATA>) {
chomp;
my ($key, $val) = split(/\s+/, $_, 2);
push @{$h{$key}}, $val;
}
foreach my $key (sort keys %h) {
foreach my $val (@{$h{$key}}) {
print "$key $val\n";
}
}
__DATA__
00:00:00 line of text
00:05:01 another line
00:00:00 second line of text
--
Jonathan Feinberg jdf@pobox.com Sunny Brooklyn, NY
------------------------------
Date: Fri, 20 Mar 1998 08:13:44 -0800
From: rdm@cfcl.com (Rich Morin)
Subject: Re: Storing and sorting numerical keys
Message-Id: <rdm-2003980813440001@140.174.42.30>
In article <3511C1DA.EBDBDD40@ozy.dec.com>, David Reilly
<reilly@ozy.dec.com> wrote:
> I want to store information (a line of text), using as my key
> a numberical number (hh:mm:ss), and then sort them.
> I was going to use an associative array, but often the
> data will have the same key, so I'd be overwriting anything
> that has a duplicate.
Using sprintf(), you could make up an artificial key, based on the
time (hh:mm:ss) and the input line number: "01:23:45:000123". This would
sort stably (preserving the input order on even matches). Be sure to use
enough leading zeroes to handle the highest possible input line number!
Getting a bit fancier, you could use a two-dimensional hash:
$m{$time}{$ndx} = $line;
but that would require more code to search and is probably overkill...
-r
--
Canta Forda Computer Laboratory | Prime Time Freeware - quality
UNIX consulting, training, & writing | freeware at affordable prices
+1 415-873-7841 | +1 408-433-9662 -0727 (Fax)
Rich Morin, rdm@cfcl.com | www.ptf.com, info@ptf.com
------------------------------
Date: Fri, 20 Mar 1998 15:35:21 GMT
From: jgloudon@manitoba.bbn.com (Jason Gloudon)
Subject: Re: Strange: die $object un-blesses the object??
Message-Id: <slrn6h533a.qdv.jgloudon@manitoba.bbn.com>
In article <VA.0000007f.04542ced@jll>, Jean-Louis Leroy wrote:
>eval
>{
> die (new runtime_error);
>};
<- code removed ->
Die converts the list it is called with into a string and in eval this string
is what gets put into $@. The output is misleading because with
print "$e\n"; # runtime_error=HASH(0x7c5568)
$e is converted to this string by the print, whereas the runtime_error object
you created in the eval was converted to a string by die. The ref() function
to understand this.
print $@, (ref($@) ? "is a reference" , "is not a reference"), "\n";
Also, the $@ message looks like
runtime_error=HASH(0x80c6490) at remote line 12.
--
Jason Gloudon
------------------------------
Date: Fri, 20 Mar 1998 11:59:15 +0000
From: Jeff Potter <jp@glpbooks.BADMAIL.com>
Subject: Re: Wanted: email address gleaner
Message-Id: <35125A13.5D29@glpbooks.BADMAIL.com>
John Stanley wrote:
[]
> There is everything spamlike about your quest, whether or not I am
> against you publishing a book of other people's articles. You have a
> strange idea of what a newsgroup archive is supposed to be for. It isn't
> supposed to be for you to make money off of.
Any offline project involving a newsgroup interest will cost money.
Whether it's volunteer, nonprofit or not is immaterial
regarding your complaint.
The rec.bicycles.racing newsgroup sells t-shirts and organizes
trips for Team Internet. Rec.hunting had a fundraiser to show
financial appreciation for its hardworking volunteer moderator.
I've had requests to reprint my NG posts in magazines.
My project is to make a paper directory of hard to find restaurants.
We've discussed the need for a permission-asking program in the
restaurant NG.
I've never seen a squawk in these NG's about any of this being spam,
nor have I felt like complaining when I've been approached similarly.
I've been involved in NG's for 8 years and thought I had a notion
about what spam was.
So I'm still not seeing what you mean.
Is it emailing someone to ask for permission to reprint
their work? Why different if I emailed everyone there who'd made a
post that I wanted to use? (Excluding duplicates of course.)
--
Jeff Potter jp@glpbooks.BADMAIL.com delete '.BADMAIL' to reply
***"Out Your Backdoor": Friendly Magazine of DIY Adventure and Culture
http://www.glpbooks.com/oyb ... with new bookstore & bulletin board
------------------------------
Date: 20 Mar 1998 10:11:01 -0500
From: charlot@CAM.ORG (Richard Bellavance)
Subject: Re: Wanted: Perl for Windows 3.x
Message-Id: <6eu0u5$s78@ocean.CAM.ORG>
In article <1.5.4.16.19980320144153.3c3f50e6@pop.netaddress.com>,
Suranga Manage <Use-Author-Address-Header@[127.1]> wrote:
>
>I am a computer eng student, I want to learn some perl. However
>I don't have access to a UNIX box. Is there a perl version that
>can be run on MS-Windows 3.1 or MS-Dos ?. I know that there
>is a perl flavour for MS-Windows NT but I am not in a position
>to have access to a NT machine.
>
I don't think Perl is available for DOS/Win 3.x, but don't take my word for
it, go to http://www.perl.com/ and make sure !
Of course, you could upgrade your machine to Linux...
Richard.
--
Richard Bellavance -- charlot@cam.org -- http://www.cam.org/~charlot/
"All along this path I tread / My heart betrays my weary head
With nothing but my love to save / From the cradle to the grave"
(Eric Clapton, "From the cradle")
------------------------------
Date: Fri, 20 Mar 1998 15:09:14 GMT
From: jgloudon@manitoba.bbn.com (Jason Gloudon)
Subject: Re: what is wrong with being a novice ??
Message-Id: <slrn6h51ia.qdv.jgloudon@manitoba.bbn.com>
In article <6etr9q$210$1@svr-c-02.core.theplanet.net>, Tony Kenny wrote:
>The only problem I find with the faq is that it is so damn long, maybe there
>could be a searchable knowledge base instead. I would be happy to program
While nowhere as advanced as an SQL searchable, cross indexed knowledge base,
a simple "Find" in netscape while viewing this page:
http://www.perl.com/CPAN-local/doc/FAQs/FAQ/PerlFAQ.html
would really give the answer most questions. But then what is a FAQ if the
questions in it aren't frequently asked ?
>could be a searchable knowledge base instead. I would be happy to program
>it if it would be used (know that I am learning a bit more, thanks Randal!
That's the real problem, most of the FAQ question askers didn't want/know/think
to look in the FAQ, so they aren't going to want/know/think to look anywhere
else, Usenet being the easiest way out.
--
Jason Gloudon
------------------------------
Date: Fri, 20 Mar 1998 10:12:24 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: what is wrong with being a novice ??
Message-Id: <fl_aggie-2003981012240001@aggie.coaps.fsu.edu>
In article <01bd5381$62758f00$474295c1@default>, "Jon Marshall"
<xkn14@dial.pipex.com> wrote:
+ That said if someone really has made an effort and they simply don't get it
Then they have nothing to worry about.
The folks who go "I know there's a faq, and documents, and books, but
I want YOU people to ANSWER me NOW" deserve all the abuse the receive.
They're the ones who get flamed.
And some people just don't understand that they have a virtual cornucopia
of documentation at their finger-tips. They simply need to be informed
of things like 'perldoc'...
James
--
Consulting Minister for Consultants, DNRC
The Bill of Rights is paid in Responsibilities - Jean McGuire
To cure your perl CGI problems, please look at:
<url:http://www.perl.com/CPAN-local/doc/FAQs/cgi/idiots-guide.html>
------------------------------
Date: 20 Mar 1998 16:22:14 GMT
From: klassa@aursgh.aur.alcatel.com (John Klassa)
Subject: Re: what is wrong with being a novice ??
Message-Id: <6eu53m$2ph$1@aurwww.aur.alcatel.com>
On Fri, 20 Mar 1998 13:22:20 -0000, Tony Kenny <tony@cyberscape.net> wrote:
->The only problem I find with the faq is that it is so damn long, maybe
->there could be a searchable knowledge base instead. I would be happy to
->program
You don't have to read the whole thing, though... Use an editor, and
search for the parts of interest. Sounds like a searchable knowledge
base to me. :-)
--
John Klassa / Alcatel Telecom / Raleigh, NC, USA <><
------------------------------
Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 8 Mar 97)
Message-Id: <null>
Administrivia:
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 2144
**************************************