*
* The original patches that introduces flexible exceptions were:
*
- * http://public.activestate.com/cgi-bin/perlbrowse?patch=3386
- * http://public.activestate.com/cgi-bin/perlbrowse?patch=5162
+ * http://perl5.git.perl.org/perl.git/commit/312caa8e97f1c7ee342a9895c2f0e749625b4929
+ * http://perl5.git.perl.org/perl.git/commit/14dd3ad8c9bf82cf09798a22cc89a9862dfd6d1a
+ *
*/
#define dJMPENV JMPENV cur_env
#define COPHH_KEY_UTF8 REFCOUNTED_HE_KEY_UTF8
/*
-=for apidoc Am|SV *|cophh_fetch_pvn|const COPHH *cophh|const char *keypv|STRLEN keylen|U32 hash|U32 flags
+=for apidoc Amx|SV *|cophh_fetch_pvn|const COPHH *cophh|const char *keypv|STRLEN keylen|U32 hash|U32 flags
Look up the entry in the cop hints hash I<cophh> with the key specified by
I<keypv> and I<keylen>. If I<flags> has the C<COPHH_KEY_UTF8> bit set,
Perl_refcounted_he_fetch_pvn(aTHX_ cophh, keypv, keylen, hash, flags)
/*
-=for apidoc Am|SV *|cophh_fetch_pvs|const COPHH *cophh|const char *key|U32 flags
+=for apidoc Amx|SV *|cophh_fetch_pvs|const COPHH *cophh|const char *key|U32 flags
Like L</cophh_fetch_pvn>, but takes a literal string instead of a
string/length pair, and no precomputed hash.
Perl_refcounted_he_fetch_pvn(aTHX_ cophh, STR_WITH_LEN(key), 0, flags)
/*
-=for apidoc Am|SV *|cophh_fetch_pv|const COPHH *cophh|const char *key|U32 hash|U32 flags
+=for apidoc Amx|SV *|cophh_fetch_pv|const COPHH *cophh|const char *key|U32 hash|U32 flags
Like L</cophh_fetch_pvn>, but takes a nul-terminated string instead of
a string/length pair.
Perl_refcounted_he_fetch_pv(aTHX_ cophh, key, hash, flags)
/*
-=for apidoc Am|SV *|cophh_fetch_sv|const COPHH *cophh|SV *key|U32 hash|U32 flags
+=for apidoc Amx|SV *|cophh_fetch_sv|const COPHH *cophh|SV *key|U32 hash|U32 flags
Like L</cophh_fetch_pvn>, but takes a Perl scalar instead of a
string/length pair.
Perl_refcounted_he_fetch_sv(aTHX_ cophh, key, hash, flags)
/*
-=for apidoc Am|HV *|cophh_2hv|const COPHH *cophh|U32 flags
+=for apidoc Amx|HV *|cophh_2hv|const COPHH *cophh|U32 flags
Generates and returns a standard Perl hash representing the full set of
key/value pairs in the cop hints hash I<cophh>. I<flags> is currently
Perl_refcounted_he_chain_2hv(aTHX_ cophh, flags)
/*
-=for apidoc Am|COPHH *|cophh_copy|COPHH *cophh
+=for apidoc Amx|COPHH *|cophh_copy|COPHH *cophh
Make and return a complete copy of the cop hints hash I<cophh>.
#define cophh_copy(cophh) Perl_refcounted_he_inc(aTHX_ cophh)
/*
-=for apidoc Am|void|cophh_free|COPHH *cophh
+=for apidoc Amx|void|cophh_free|COPHH *cophh
Discard the cop hints hash I<cophh>, freeing all resources associated
with it.
#define cophh_free(cophh) Perl_refcounted_he_free(aTHX_ cophh)
/*
-=for apidoc Am|COPHH *|cophh_new_empty
+=for apidoc Amx|COPHH *|cophh_new_empty
Generate and return a fresh cop hints hash containing no entries.
#define cophh_new_empty() ((COPHH *)NULL)
/*
-=for apidoc Am|COPHH *|cophh_store_pvn|COPHH *cophh|const char *keypv|STRLEN keylen|U32 hash|SV *value|U32 flags
+=for apidoc Amx|COPHH *|cophh_store_pvn|COPHH *cophh|const char *keypv|STRLEN keylen|U32 hash|SV *value|U32 flags
Stores a value, associated with a key, in the cop hints hash I<cophh>,
and returns the modified hash. The returned hash pointer is in general
Perl_refcounted_he_new_pvn(aTHX_ cophh, keypv, keylen, hash, value, flags)
/*
-=for apidoc Am|COPHH *|cophh_store_pvs|const COPHH *cophh|const char *key|SV *value|U32 flags
+=for apidoc Amx|COPHH *|cophh_store_pvs|const COPHH *cophh|const char *key|SV *value|U32 flags
Like L</cophh_store_pvn>, but takes a literal string instead of a
string/length pair, and no precomputed hash.
Perl_refcounted_he_new_pvn(aTHX_ cophh, STR_WITH_LEN(key), 0, value, flags)
/*
-=for apidoc Am|COPHH *|cophh_store_pv|const COPHH *cophh|const char *key|U32 hash|SV *value|U32 flags
+=for apidoc Amx|COPHH *|cophh_store_pv|const COPHH *cophh|const char *key|U32 hash|SV *value|U32 flags
Like L</cophh_store_pvn>, but takes a nul-terminated string instead of
a string/length pair.
Perl_refcounted_he_new_pv(aTHX_ cophh, key, hash, value, flags)
/*
-=for apidoc Am|COPHH *|cophh_store_sv|const COPHH *cophh|SV *key|U32 hash|SV *value|U32 flags
+=for apidoc Amx|COPHH *|cophh_store_sv|const COPHH *cophh|SV *key|U32 hash|SV *value|U32 flags
Like L</cophh_store_pvn>, but takes a Perl scalar instead of a
string/length pair.
Perl_refcounted_he_new_sv(aTHX_ cophh, key, hash, value, flags)
/*
-=for apidoc Am|COPHH *|cophh_delete_pvn|COPHH *cophh|const char *keypv|STRLEN keylen|U32 hash|U32 flags
+=for apidoc Amx|COPHH *|cophh_delete_pvn|COPHH *cophh|const char *keypv|STRLEN keylen|U32 hash|U32 flags
Delete a key and its associated value from the cop hints hash I<cophh>,
and returns the modified hash. The returned hash pointer is in general
(SV *)NULL, flags)
/*
-=for apidoc Am|COPHH *|cophh_delete_pvs|const COPHH *cophh|const char *key|U32 flags
+=for apidoc Amx|COPHH *|cophh_delete_pvs|const COPHH *cophh|const char *key|U32 flags
Like L</cophh_delete_pvn>, but takes a literal string instead of a
string/length pair, and no precomputed hash.
(SV *)NULL, flags)
/*
-=for apidoc Am|COPHH *|cophh_delete_pv|const COPHH *cophh|const char *key|U32 hash|U32 flags
+=for apidoc Amx|COPHH *|cophh_delete_pv|const COPHH *cophh|const char *key|U32 hash|U32 flags
Like L</cophh_delete_pvn>, but takes a nul-terminated string instead of
a string/length pair.
Perl_refcounted_he_new_pv(aTHX_ cophh, key, hash, (SV *)NULL, flags)
/*
-=for apidoc Am|COPHH *|cophh_delete_sv|const COPHH *cophh|SV *key|U32 hash|U32 flags
+=for apidoc Amx|COPHH *|cophh_delete_sv|const COPHH *cophh|SV *key|U32 hash|U32 flags
Like L</cophh_delete_pvn>, but takes a Perl scalar instead of a
string/length pair.
/* If $[ is non-zero, it's stored in cop_hints under the key "$[", and
HINT_ARYBASE is set to indicate this.
- Setting it is ineficient due to the need to create 2 mortal SVs, but as
+ Setting it is inefficient due to the need to create 2 mortal SVs, but as
using $[ is highly discouraged, no sane Perl code will be using it. */
#define CopARYBASE_get(c) \
((CopHINTS_get(c) & HINT_ARYBASE) \
#define PUSHSUB_BASE(cx) \
ENTRY_PROBE(GvENAME(CvGV(cv)), \
CopFILE((const COP *)CvSTART(cv)), \
- CopLINE((const COP *)CvSTART(cv))); \
+ CopLINE((const COP *)CvSTART(cv)), \
+ CopSTASHPV((const COP *)CvSTART(cv))); \
\
cx->blk_sub.cv = cv; \
cx->blk_sub.olddepth = CvDEPTH(cv); \
STMT_START { \
RETURN_PROBE(GvENAME(CvGV((const CV*)cx->blk_sub.cv)), \
CopFILE((COP*)CvSTART((const CV*)cx->blk_sub.cv)), \
- CopLINE((COP*)CvSTART((const CV*)cx->blk_sub.cv))); \
+ CopLINE((COP*)CvSTART((const CV*)cx->blk_sub.cv)), \
+ CopSTASHPV((COP*)CvSTART((const CV*)cx->blk_sub.cv))); \
\
if (CxHASARGS(cx)) { \
POP_SAVEARRAY(); \
#define sb_maxiters cx_u.cx_subst.sbu_maxiters
#define sb_rflags cx_u.cx_subst.sbu_rflags
#define sb_oldsave cx_u.cx_subst.sbu_oldsave
-#define sb_once cx_u.cx_subst.sbu_once
#define sb_rxtainted cx_u.cx_subst.sbu_rxtainted
#define sb_orig cx_u.cx_subst.sbu_orig
#define sb_dstr cx_u.cx_subst.sbu_dstr
#define G_UNDEF_FILL 512 /* Fill the stack with &PL_sv_undef
A special case for UNSHIFT in
Perl_magic_methcall(). */
+#define G_WRITING_TO_STDERR 1024 /* Perl_write_to_stderr() is calling
+ Perl_magic_methcall(). */
/* flag bits for PL_in_eval */
#define EVAL_NULL 0 /* not in an eval */