In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/8368298acf5c578b88887f19f7fba519bbc12296?hp=35146e33497dadaa6d9dff57c12764af3e85b229>

- Log -----------------------------------------------------------------
commit 8368298acf5c578b88887f19f7fba519bbc12296
Author: Tony Cook <[email protected]>
Date:   Thu Dec 2 23:03:57 2010 +1100

    Fix C++ breakage introduced in d7ef4b73
    
    C++ doesn't allow goto or switch to bypass initialized variable
    declarations.  Also fix the function pointer type.
-----------------------------------------------------------------------

Summary of changes:
 regexec.c |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/regexec.c b/regexec.c
index ffa2da4..d21614f 100644
--- a/regexec.c
+++ b/regexec.c
@@ -3931,11 +3931,15 @@ S_regmatch(pTHX_ regmatch_info *reginfo, regnode *prog)
               named buffers just convert to the equivalent numbered and
               pretend they were called as the corresponding numbered buffer
               op.  */
+           /* don't initialize these, it makes C++ unhappy */
            char *s;
            char type;
-           I32 (*folder)() = NULL;     /* NULL assumes will be NREF, REF: no
-                                          folding */
-           const U8 * fold_array = NULL;
+           re_fold_t folder;
+           const U8 *fold_array;
+
+           folder = NULL;      /* NULL assumes will be NREF, REF: no
+                                  folding */
+           fold_array = NULL;
 
            PL_reg_flags |= RF_tainted;
            folder = foldEQ_locale;

--
Perl5 Master Repository

Reply via email to