5 $SIG{__DIE__} = sub { print ref($_[0]) ? ("ok ",$_[0]->[0]++,"\n") : @_ } ;
7 $err = "#[\000]\nok 1\n";
12 print "not " unless $@ eq $err;
18 print "not " unless $x->[0] == 4;
30 die bless [ 7 ], "Error";
35 print "not " unless ref($@) eq "Out";
42 print "ok ",$_[0]->[0]++,"\n";
43 bless [$_[0]->[0]], "Out";
51 my $msg = "ce ºtii tu, bã ?\n";
52 eval { die $msg }; print "not " unless $@ eq $msg;
55 local $SIG{__WARN__} = $SIG{__DIE__} = sub { $err = shift };
56 eval { die $msg }; print "not " unless $err eq $msg;
58 eval { warn $msg }; print "not " unless $err eq $msg;
60 eval qq/ use strict; \$\x{3b1} /;
61 print "not " unless $@ =~ /Global symbol "\$\x{3b1}"/;
65 # [perl #36470] got uninit warning if $@ was undef
70 local $SIG{__WARN__} = sub { $ok = 0 };
71 eval { undef $@; die };
72 print "not " unless $ok;