From 1a0a2ba99e0c0ff795f145aaf54fcf0c4a8f7478 Mon Sep 17 00:00:00 2001 From: Zefram Date: Mon, 16 Aug 2010 20:22:42 +0100 Subject: make recursive part of peephole optimiser hookable New variable PL_rpeepp makes it possible for extensions to hook the per-op-chain part of the peephole optimiser (which recurses into side chains). The existing variable PL_peepp still allows hooking the per-sub part of the peephole optimiser, maintaining perfect backward compatibility. --- intrpvar.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'intrpvar.h') diff --git a/intrpvar.h b/intrpvar.h index 21fb933254..503d9d666f 100644 --- a/intrpvar.h +++ b/intrpvar.h @@ -172,7 +172,9 @@ PERLVARI(Irehash_seed_set, bool, FALSE) /* 582 hash initialized? */ PERLVARA(Icolors,6, char *) /* from regcomp.c */ PERLVARI(Ipeepp, peep_t, MEMBER_TO_FPTR(Perl_peep)) - /* Pointer to peephole optimizer */ + /* Pointer to per-sub peephole optimizer */ +PERLVARI(Irpeepp, peep_t, MEMBER_TO_FPTR(Perl_rpeep)) + /* Pointer to recursive peephole optimizer */ /* =for apidoc Amn|Perl_ophook_t|PL_opfreehook -- cgit v1.2.1