diff options
author | Nicholas Clark <nick@ccl4.org> | 2008-11-26 22:25:18 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2008-11-26 22:25:18 +0000 |
commit | 9c105995f0120a86f489fa9da8e150fc55635f02 (patch) | |
tree | 1616d443a1213e27344ffb50679b59392fae193a /cop.h | |
parent | 1f676739c0ff005ad6d6d4d3691c095800bc458c (diff) | |
download | perl-9c105995f0120a86f489fa9da8e150fc55635f02.tar.gz |
rxres_free() and rxres_restore() are only used in pp_ctl.c, so can be
static. Macros PUSHSUBST() and POPSUBST() are only viable in PERL_CORE.
p4raw-id: //depot/perl@34935
Diffstat (limited to 'cop.h')
-rw-r--r-- | cop.h | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -610,7 +610,8 @@ struct subst { #define sb_rxres cx_u.cx_subst.sbu_rxres #define sb_rx cx_u.cx_subst.sbu_rx -#define PUSHSUBST(cx) CXINC, cx = &cxstack[cxstack_ix], \ +#ifdef PERL_CORE +# define PUSHSUBST(cx) CXINC, cx = &cxstack[cxstack_ix], \ cx->sb_iters = iters, \ cx->sb_maxiters = maxiters, \ cx->sb_rflags = r_flags, \ @@ -628,11 +629,12 @@ struct subst { rxres_save(&cx->sb_rxres, rx); \ (void)ReREFCNT_inc(rx) -#define CxONCE(cx) ((cx)->cx_type & CXp_ONCE) - -#define POPSUBST(cx) cx = &cxstack[cxstack_ix--]; \ +# define POPSUBST(cx) cx = &cxstack[cxstack_ix--]; \ rxres_free(&cx->sb_rxres); \ ReREFCNT_dec(cx->sb_rx) +#endif + +#define CxONCE(cx) ((cx)->cx_type & CXp_ONCE) struct context { union { |