SPUG: die from BEGIN; how suppress ugly message?
Rick Croote
rcroot at atl.com
Wed Jan 26 17:01:01 CST 2000
I do not get any ugly messages while using "exit" from within a BEGIN block.
I do get them from "die", no matter what. I didn't try your method in your
follow up.
---
Rick Croote
ATL Ultrasound
----- Original Message -----
From: Tim Maher/CONSULTIX <tim at consultix-inc.com>
To: <spug-list at pm.org>
Sent: Wednesday, January 26, 2000 2:00 PM
Subject: SPUG: die from BEGIN; how suppress ugly message?
> SPUGicans,
>
> Does anybody know an elegant, simple (might be asking too much there)
> way to trap/suppress/avoid this kind of ugly message when I call
> exit or die from within BEGIN?
>
> $ turbo_fax
> Usage: turbo_fax file1 [file2 . . .]
> BEGIN failed--compilation aborted at ./in_place line 19.
> $
>
> In some cases, I can set a flag in BEGIN and have "$fatal and die"
> as the first line of the program body, but if I'm using -n/-p, I
> need to get a line of input before dying, which ruins that approach.
>
> There should be a way . . . What it is? 8-}
>
> -Tim
> P.S. Going for a personal daily-posting record today! If I don't shutup,
> as the list-owner I'll have to rebuke myself!
>
> *========================================================================*
> | Tim Maher, PhD Consultix & (206) 781-UNIX/8649 |
> | Pacific Software Gurus, Inc Email: tim at consultix-inc.com |
> | UNIX/Linux & Perl Training http://www.consultix-inc.com |
> | 2/22: UNIX 2/28: Perl Modules 2/29: Int. Perl 3/3: Pattern Matching |
> *========================================================================*
>
> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> POST TO: spug-list at pm.org PROBLEMS: owner-spug-list at pm.org
> Seattle Perl Users Group (SPUG) Home Page: http://www.halcyon.com/spug/
> SUBSCRIBE/UNSUBSCRIBE: Replace ACTION below by subscribe or unsubscribe
> Email to majordomo at pm.org: ACTION spug-list your_address
>
>
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
POST TO: spug-list at pm.org PROBLEMS: owner-spug-list at pm.org
Seattle Perl Users Group (SPUG) Home Page: http://www.halcyon.com/spug/
SUBSCRIBE/UNSUBSCRIBE: Replace ACTION below by subscribe or unsubscribe
Email to majordomo at pm.org: ACTION spug-list your_address
More information about the spug-list
mailing list