On Mon, 3 Dec 2001, Dean Theophilou wrote:

>       I would like to exit a perl program such that upon exiting, it will return a
> text string to the calling program.  How would I go about doing this?
>
> exit $SomeTextString;
>
> doesn't work, since "exit" evaluates the above scalar as an integer.  Thank you
> in advance.

Return a text-string in what manner?  If the calling program is picking
something out of STDIN, then you will want to use die:

die "Error doing something" if $some_error_condition;

-- Brett
                                          http://www.chapelperilous.net/
------------------------------------------------------------------------
        Idaho state law makes it illegal for a man to give his sweetheart
a box of candy weighing less than fifty pounds.


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to