Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Re: Confusion about properly using Carp

by koolade (Pilgrim)
on Mar 02, 2002 at 17:06 UTC ( #148845=note: print w/replies, xml ) Need Help??


in reply to Re: Confusion about properly using Carp
in thread Confusion about properly using Carp

He's calling carp() from Foo.pm, not DBI.pm, so this won't accomplish what he's asking.
  • Comment on Re: Re: Confusion about properly using Carp

Replies are listed 'Best First'.
Re: Re: Re: Confusion about properly using Carp
by Juerd (Abbot) on Mar 02, 2002 at 17:19 UTC
    I was thinking along the lines of: (warning: untested code ahead)
    package Foo; ... our $error; *DBI::carp = sub { $Foo::error = shift }; ... my $self->{dbh} = DBI->connect( ... ) or carp $error;

    Lbh ebgngrq guvf grkg naq abj lbh pna ernq vg. Fb jung? :) -- Whreq

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://148845]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2022-08-10 13:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?