This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Rename local variable to prevent confusion with global
authorJames E Keenan <jkeenan@cpan.org>
Mon, 26 Nov 2018 17:29:03 +0000 (12:29 -0500)
committerJames E Keenan <jkeenan@cpan.org>
Mon, 26 Nov 2018 17:29:03 +0000 (12:29 -0500)
Per:  https://lgtm.com/projects/g/Perl/perl5/alerts/?mode=tree&ruleFocus=2157860312

For: RT # 133686 (partial)

locale.c

index ff6322f..c32dd3f 100644 (file)
--- a/locale.c
+++ b/locale.c
@@ -5050,15 +5050,15 @@ Perl__is_in_locale_category(pTHX_ const bool compiling, const int category)
 
     const COP * const cop = (compiling) ? &PL_compiling : PL_curcop;
 
 
     const COP * const cop = (compiling) ? &PL_compiling : PL_curcop;
 
-    SV *categories = cop_hints_fetch_pvs(cop, "locale", 0);
-    if (! categories || categories == &PL_sv_placeholder) {
+    SV *these_categories = cop_hints_fetch_pvs(cop, "locale", 0);
+    if (! these_categories || these_categories == &PL_sv_placeholder) {
         return FALSE;
     }
 
     /* The pseudo-category 'not_characters' is -1, so just add 1 to each to get
      * a valid unsigned */
     assert(category >= -1);
         return FALSE;
     }
 
     /* The pseudo-category 'not_characters' is -1, so just add 1 to each to get
      * a valid unsigned */
     assert(category >= -1);
-    return cBOOL(SvUV(categories) & (1U << (category + 1)));
+    return cBOOL(SvUV(these_categories) & (1U << (category + 1)));
 }
 
 char *
 }
 
 char *