This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
rarest is only used under -DDEBUGGING
authorTony Cook <tony@develop-help.com>
Thu, 4 Jul 2013 06:20:40 +0000 (16:20 +1000)
committerTony Cook <tony@develop-help.com>
Thu, 4 Jul 2013 06:20:40 +0000 (16:20 +1000)
This was warning under gcc 4.7.2

util.c

diff --git a/util.c b/util.c
index 01f441b..42c4f66 100644 (file)
--- a/util.c
+++ b/util.c
@@ -521,9 +521,9 @@ Perl_fbm_compile(pTHX_ SV *sv, U32 flags)
     const U8 *s;
     STRLEN i;
     STRLEN len;
     const U8 *s;
     STRLEN i;
     STRLEN len;
-    STRLEN rarest = 0;
     U32 frequency = 256;
     MAGIC *mg;
     U32 frequency = 256;
     MAGIC *mg;
+    PERL_DEB( STRLEN rarest = 0 );
 
     PERL_ARGS_ASSERT_FBM_COMPILE;
 
 
     PERL_ARGS_ASSERT_FBM_COMPILE;
 
@@ -591,7 +591,7 @@ Perl_fbm_compile(pTHX_ SV *sv, U32 flags)
     s = (const unsigned char*)(SvPVX_const(sv));       /* deeper magic */
     for (i = 0; i < len; i++) {
        if (PL_freq[s[i]] < frequency) {
     s = (const unsigned char*)(SvPVX_const(sv));       /* deeper magic */
     for (i = 0; i < len; i++) {
        if (PL_freq[s[i]] < frequency) {
-           rarest = i;
+           PERL_DEB( rarest = i );
            frequency = PL_freq[s[i]];
        }
     }
            frequency = PL_freq[s[i]];
        }
     }