#!/usr/bin/perl
use strict;
use Foo;
die('this will appear in the error log like expected');
####
#!/usr/bin/perl
use strict;
use Foo;
# here, something happens that messes up the die handler?
my $foo = Foo->new();
die('this will NOT appear in the error log at all');
####
#!/usr/bin/perl
use strict;
use Foo;
# here, something happens that messes up the die handler?
my $foo = Foo->new();
# but this apparently fixes it:
undef $foo;
die('this DOES appear in the error log');
####
local $SIG{__DIE__} = ''; # no effect
local $SIG{__DIE__} = 'DEFAULT'; # no effect
# this gives a warning in the error log, no error
local $SIG{__DIE__} = sub { warn @_ };
# this has no effect, nothing at all in the logs:
local $SIG{__DIE__} = sub { die @_ };
####
die SOAP::Fault->new(..);