This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
regexec.c: change variable name to its purpose
authorKarl Williamson <public@khwilliamson.com>
Sun, 7 Nov 2010 21:17:27 +0000 (14:17 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Mon, 8 Nov 2010 05:42:42 +0000 (21:42 -0800)
regexec.c

index d95b27a..433bbeb 100644 (file)
--- a/regexec.c
+++ b/regexec.c
@@ -6335,12 +6335,14 @@ S_reginclass(pTHX_ const regexp * const prog, register const regnode * const n,
                        }
                    }
                    if (!match) {
                        }
                    }
                    if (!match) {
-                       U8 tmpbuf[UTF8_MAXBYTES_CASE+1];
+                       U8 folded[UTF8_MAXBYTES_CASE+1];
 
 
-                       STRLEN tmplen;
-                       to_utf8_fold(utf8_p, tmpbuf, &tmplen);
-                       if (swash_fetch(sw, tmpbuf, 1))
+                       /* See if the folded version matches */
+                       STRLEN foldlen;
+                       to_utf8_fold(utf8_p, folded, &foldlen);
+                       if (swash_fetch(sw, folded, 1)) {   /* 1 => is utf8 */
                            match = TRUE;
                            match = TRUE;
+                       }
                    }
                }
 
                    }
                }