These lists are read-only. Turning on the flag may allow some
optimisations to be done, including some that may be added in the
future.
/* Initialize the iteration pointer. */
invlist_iterfinish(invlist);
+ SvREADONLY_on(invlist);
+
return invlist;
}
#endif /* ifndef PERL_IN_XSUB_RE */
else SvREFCNT_inc_simple_void_NN(swash_invlist);
}
+ SvREADONLY_on(swash_invlist);
+
/* Use the inversion list stand-alone if small enough */
if ((int) _invlist_len(swash_invlist) <= invlist_swash_boundary) {
SvREFCNT_dec(retval);
sv_free(other); /* through with it! */
}
+ SvREADONLY_on(invlist);
return invlist;
}