void
Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bool dumpops, STRLEN pvlim)
{
+ dVAR;
SV *d;
const char *s;
U32 flags;
* values for our db, instead of trying to change them.
* */
+ dVAR;
+
int ok = 1;
#ifndef USE_LOCALE
STATIC void
S_maybe_multiconcat(pTHX_ OP *o)
{
+ dVAR;
OP *lastkidop; /* the right-most of any kids unshifted onto o */
OP *topop; /* the top-most op in the concat tree (often equals o,
unless there are assign/stringify ops above it */
static OP *
S_newONCEOP(pTHX_ OP *initop, OP *padop)
{
+ dVAR;
const PADOFFSET target = padop->op_targ;
OP *const other = newOP(OP_PADSV,
padop->op_flags
PP(pp_uc)
{
+ dVAR;
dSP;
SV *source = TOPs;
STRLEN len;
* returned list must, and will, contain every code point that is a
* possibility. */
+ dVAR;
SV* invlist = NULL;
SV* only_utf8_locale_invlist = NULL;
unsigned int i;
/* recursed: which subroutines have we recursed into */
/* and_withp: Valid if flags & SCF_DO_STCLASS_OR */
{
+ dVAR;
/* There must be at least this number of characters to match */
SSize_t min = 0;
I32 pars = 0, code;
OP *expr, const regexp_engine* eng, REGEXP *old_re,
bool *is_bare_re, const U32 orig_rx_flags, const U32 pm_flags)
{
+ dVAR;
REGEXP *Rx; /* Capital 'R' means points to a REGEXP */
STRLEN plen;
char *exp;
STATIC SV*
S__make_exactf_invlist(pTHX_ RExC_state_t *pRExC_state, regnode *node)
{
+ dVAR;
const U8 * s = (U8*)STRING(node);
SSize_t bytelen = STR_LEN(node);
UV uc;
STATIC regnode_offset
S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
{
+ dVAR;
regnode_offset ret = 0;
I32 flags = 0;
char *parse_start;
* sets up the bitmap and any flags, removing those code points from the
* inversion list, setting it to NULL should it become completely empty */
+ dVAR;
+
PERL_ARGS_ASSERT_POPULATE_ANYOF_FROM_INVLIST;
assert(PL_regkind[OP(node)] == ANYOF);
* UTF-8
*/
+ dVAR;
UV prevvalue = OOB_UNICODE, save_prevvalue = OOB_UNICODE;
IV range = 0;
UV value = OOB_UNICODE, save_value = OOB_UNICODE;
Perl_regprop(pTHX_ const regexp *prog, SV *sv, const regnode *o, const regmatch_info *reginfo, const RExC_state_t *pRExC_state)
{
#ifdef DEBUGGING
+ dVAR;
int k;
RXi_GET_DECL(prog, progi);
GET_RE_DEBUG_FLAGS_DECL;
* output would have been only the inversion indicator '^', NULL is instead
* returned. */
+ dVAR;
SV * output;
PERL_ARGS_ASSERT_PUT_CHARCLASS_BITMAP_INNARDS_COMMON;
* whether the class itself is to be inverted. However, there are some
* cases where it can't try inverting, as what actually matches isn't known
* until runtime, and hence the inversion isn't either. */
+
+ dVAR;
bool inverting_allowed = ! force_as_is_display;
int i;
void
Perl_init_uniprops(pTHX)
{
+ dVAR;
+
PL_user_def_props = newHV();
#ifdef USE_ITHREADS
* properties. This is a function so it can be set up to be called even if
* the program unexpectedly quits */
+ dVAR;
SV ** current_entry;
const STRLEN key_len = strlen((const char *) key);
DECLARATION_FOR_GLOBAL_CONTEXT;
this */
const STRLEN level) /* Recursion level of this call */
{
+ dVAR;
char* lookup_name; /* normalized name for lookup in our tables */
unsigned lookup_len; /* Its length */
bool stricter = FALSE; /* Some properties have stricter name
* rules, ignoring any locale. So use the Unicode function if this class
* requires an inversion list, and use the Unicode macro otherwise. */
+ dVAR;
+
PERL_ARGS_ASSERT_ISFOO_UTF8_LC;
if (UTF8_IS_INVARIANT(*character)) {
STATIC GCB_enum
S_backup_one_GCB(pTHX_ const U8 * const strbeg, U8 ** curpos, const bool utf8_target)
{
+ dVAR;
GCB_enum gcb;
PERL_ARGS_ASSERT_BACKUP_ONE_GCB;
STATIC LB_enum
S_advance_one_LB(pTHX_ U8 ** curpos, const U8 * const strend, const bool utf8_target)
{
+ dVAR;
+
LB_enum lb;
PERL_ARGS_ASSERT_ADVANCE_ONE_LB;
STATIC LB_enum
S_backup_one_LB(pTHX_ const U8 * const strbeg, U8 ** curpos, const bool utf8_target)
{
+ dVAR;
LB_enum lb;
PERL_ARGS_ASSERT_BACKUP_ONE_LB;
STATIC SB_enum
S_advance_one_SB(pTHX_ U8 ** curpos, const U8 * const strend, const bool utf8_target)
{
+ dVAR;
SB_enum sb;
PERL_ARGS_ASSERT_ADVANCE_ONE_SB;
STATIC SB_enum
S_backup_one_SB(pTHX_ const U8 * const strbeg, U8 ** curpos, const bool utf8_target)
{
+ dVAR;
SB_enum sb;
PERL_ARGS_ASSERT_BACKUP_ONE_SB;
const bool utf8_target,
const bool skip_Extend_Format)
{
+ dVAR;
WB_enum wb;
PERL_ARGS_ASSERT_ADVANCE_ONE_WB;
STATIC WB_enum
S_backup_one_WB(pTHX_ WB_enum * previous, const U8 * const strbeg, U8 ** curpos, const bool utf8_target)
{
+ dVAR;
WB_enum wb;
PERL_ARGS_ASSERT_BACKUP_ONE_WB;
S_regrepeat(pTHX_ regexp *prog, char **startposp, const regnode *p,
regmatch_info *const reginfo, I32 max _pDEPTH)
{
+ dVAR;
char *scan; /* Pointer to current position in target string */
I32 c;
char *loceol = reginfo->strend; /* local version */
* so code using it would then break), and there has to be a GCB break
* before and after the character. */
+ dVAR;
+
GCB_enum cp_gcb_val, prev_cp_gcb_val, next_cp_gcb_val;
const U8 * prev_cp_start;
* characters for at least one language in the Unicode Common Locale Data
* Repository [CLDR]. */
+ dVAR;
/* Things that match /\d/u */
SV * decimals_invlist = PL_XPosix_ptrs[_CC_DIGIT];
void
Perl_init_constants(pTHX)
{
+ dVAR;
+
SvREFCNT(&PL_sv_undef) = SvREFCNT_IMMORTAL;
SvFLAGS(&PL_sv_undef) = SVf_READONLY|SVf_PROTECT|SVt_NULL;
SvANY(&PL_sv_undef) = NULL;
* interior, hence to the "}". Finds what the name resolves to, returning
* an SV* containing it; NULL if no valid one found */
+ dVAR;
SV* res = newSVpvn_flags(s, e - s, UTF ? SVf_UTF8 : 0);
HV * table;
bool
Perl__is_uni_FOO(pTHX_ const U8 classnum, const UV c)
{
+ dVAR;
return _invlist_contains_cp(PL_XPosix_ptrs[classnum], c);
}
bool
Perl__is_utf8_idstart(pTHX_ const U8 *p)
{
+ dVAR;
+
PERL_ARGS_ASSERT__IS_UTF8_IDSTART;
if (*p == '_')
bool
Perl__is_uni_perl_idcont(pTHX_ UV c)
{
+ dVAR;
return _invlist_contains_cp(PL_utf8_perl_idcont, c);
}
bool
Perl__is_uni_perl_idstart(pTHX_ UV c)
{
+ dVAR;
return _invlist_contains_cp(PL_utf8_perl_idstart, c);
}
* The ordinal of the first character of the changed version is returned
* (but note, as explained above, that there may be more.) */
+ dVAR;
PERL_ARGS_ASSERT_TO_UNI_UPPER;
if (c < 256) {
UV
Perl_to_uni_title(pTHX_ UV c, U8* p, STRLEN *lenp)
{
+ dVAR;
PERL_ARGS_ASSERT_TO_UNI_TITLE;
if (c < 256) {
UV
Perl_to_uni_lower(pTHX_ UV c, U8* p, STRLEN *lenp)
{
+ dVAR;
PERL_ARGS_ASSERT_TO_UNI_LOWER;
if (c < 256) {
* FOLD_FLAGS_NOMIX_ASCII iff non-ASCII to ASCII folds are prohibited
*/
+ dVAR;
PERL_ARGS_ASSERT__TO_UNI_FOLD_FLAGS;
if (flags & FOLD_FLAGS_LOCALE) {
const char * const file,
const unsigned line)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_FOO;
warn_on_first_deprecated_use(name, alternative, use_locale, file, line);
Perl__is_utf8_FOO_with_len(pTHX_ const U8 classnum, const U8 *p,
const U8 * const e)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_FOO_WITH_LEN;
return is_utf8_common_with_len(p, e, PL_XPosix_ptrs[classnum]);
bool
Perl__is_utf8_perl_idstart_with_len(pTHX_ const U8 *p, const U8 * const e)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_PERL_IDSTART_WITH_LEN;
return is_utf8_common_with_len(p, e, PL_utf8_perl_idstart);
bool
Perl__is_utf8_xidstart(pTHX_ const U8 *p)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_XIDSTART;
if (*p == '_')
bool
Perl__is_utf8_perl_idcont_with_len(pTHX_ const U8 *p, const U8 * const e)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_PERL_IDCONT_WITH_LEN;
return is_utf8_common_with_len(p, e, PL_utf8_perl_idcont);
bool
Perl__is_utf8_idcont(pTHX_ const U8 *p)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_IDCONT;
return is_utf8_common(p, PL_utf8_idcont);
bool
Perl__is_utf8_xidcont(pTHX_ const U8 *p)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_XIDCONT;
return is_utf8_common(p, PL_utf8_xidcont);
bool
Perl__is_utf8_mark(pTHX_ const U8 *p)
{
+ dVAR;
PERL_ARGS_ASSERT__IS_UTF8_MARK;
return is_utf8_common(p, PL_utf8_mark);
* the return can point to them, but single code points aren't, so would
* need to be constructed if we didn't employ something like this API */
+ dVAR;
/* 'index' is guaranteed to be non-negative, as this is an inversion map
* that covers all possible inputs. See [perl #133365] */
SSize_t index = _invlist_search(PL_utf8_foldclosures, cp);
* sequence, and the entire sequence will be stored in *ustrp. ustrp will
* contain *lenp bytes */
+ dVAR;
PERL_ARGS_ASSERT_TURKIC_LC;
assert(e > p0);
const char * const file,
const int line)
{
+ dVAR;
UV result;
const U32 utf8n_flags = check_and_deprecate(p, &e, DEPRECATE_TO_UPPER,
cBOOL(flags), file, line);
const char * const file,
const int line)
{
+ dVAR;
UV result;
const U32 utf8n_flags = check_and_deprecate(p, &e, DEPRECATE_TO_TITLE,
cBOOL(flags), file, line);
const char * const file,
const int line)
{
+ dVAR;
UV result;
const U32 utf8n_flags = check_and_deprecate(p, &e, DEPRECATE_TO_LOWER,
cBOOL(flags), file, line);
const char * const file,
const int line)
{
+ dVAR;
UV result;
const U32 utf8n_flags = check_and_deprecate(p, &e, DEPRECATE_TO_FOLD,
cBOOL(flags), file, line);
STATIC bool
S_invoke_exception_hook(pTHX_ SV *ex, bool warn)
{
+ dVAR;
HV *stash;
GV *gv;
CV *cv;
static void
out_of_memory(void)
{
+ dVAR;
+
if (PL_curinterp)
croak_no_mem();
exit(1);
void
Perl_sys_intern_init(pTHX)
{
+ dVAR;
int i;
w32_perlshell_tokens = NULL;
void
Perl_sys_intern_clear(pTHX)
{
+ dVAR;
+
Safefree(w32_perlshell_tokens);
Safefree(w32_perlshell_vec);
/* NOTE: w32_fdpid is freed by sv_clean_all() */