As seen on P5P.
-R
=== Forwarded Message:
Date: Mon, 3 May 2004 22:47:27 +0100
From: Dave Mitchell <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Re: [perl #29094] prefix errors with name of program
On Fri, Apr 23, 2004 at 06:00:06AM -0000, Dan Jacobson wrote:
> Today again lots of head scratching because bash and perl don't prefix
> their error messages with a "bash:" or a "perl:", so bash scripts with
> bits of perl often take deep scrutinization to figure out what the
> problem was.
That may well be the case, but Perl has done its error messages this way
for 16 years, and changing it now would boringly break lots of things.
If you're really desperate for this feature, you can do something like
this:
$ ./perl -e '$SIG{__DIE__}=sub{print STDERR"Perl: ",@_;exit 1}; $x/=$y'
Perl: Illegal division by zero at -e line 1.
--
The Enterprise successfully ferries an alien VIP from one place to another
without serious incident.
-- Things That Never Happen in "Star Trek" #7
=== End of Forwarded Message