diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 1998-05-29 07:22:51 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1998-05-29 07:22:51 +0000 |
commit | d0340efeaf607d2e70273b4fa22e5ee3b358abe8 (patch) | |
tree | 8187e35c8e61d21279785c869e1a5d92009e8e57 /pp_sys.c | |
parent | ab39fa9dbf3b1a1fb7beb555653d0558a089397f (diff) | |
parent | a1737d5b9df80320e5be59ab8fa7c96455d6b5bf (diff) | |
download | perl-d0340efeaf607d2e70273b4fa22e5ee3b358abe8.tar.gz |
[asperl] integrate mainline changes
p4raw-id: //depot/asperl@1055
Diffstat (limited to 'pp_sys.c')
-rw-r--r-- | pp_sys.c | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -324,6 +324,23 @@ PP(pp_die) if(tmpsv ? SvROK(tmpsv) : SvROK(error)) { if(tmpsv) SvSetSV(error,tmpsv); + else if(sv_isobject(error)) { + HV *stash = SvSTASH(SvRV(error)); + GV *gv = gv_fetchmethod(stash, "PROPAGATE"); + if (gv) { + SV *file = sv_2mortal(newSVsv(GvSV(curcop->cop_filegv))); + SV *line = sv_2mortal(newSViv(curcop->cop_line)); + EXTEND(SP, 3); + PUSHMARK(SP); + PUSHs(error); + PUSHs(file); + PUSHs(line); + PUTBACK; + perl_call_sv((SV*)GvCV(gv), + G_SCALAR|G_EVAL|G_KEEPERR); + sv_setsv(error,*stack_sp--); + } + } pat = Nullch; } else { |