STRLEN skip = do_utf8 ? UTF8SKIP(s) : 1;
if (reginclass(c, (U8*)s, do_utf8) ||
- (ANYOF_UNICODE_FOLD_SHARP_S(c, s, strend) &&
- (skip = 2))) {
+ (ANYOF_FOLD_SHARP_S(c, s, strend) &&
+ /* The assignment of 2 is intentional:
+ * for the sharp s, the skip is 2. */
+ (skip = SHARP_S_SKIP)
+ )) {
if (tmp && (norun || regtry(prog, s)))
goto got_it;
else
char *l = locinput;
char *e = PL_regeol;
- if (ibcmp_utf8(s, 0, ln, do_utf8,
- l, &e, 0, UTF)) {
+ if (ibcmp_utf8(s, 0, ln, UTF,
+ l, &e, 0, do_utf8)) {
/* One more case for the sharp s:
* pack("U0U*", 0xDF) =~ /ss/i,
* the 0xC3 0x9F are the UTF-8
/* If we might have the case of the German sharp s
* in a casefolding Unicode character class. */
- if (ANYOF_UNICODE_FOLD_SHARP_S(scan, locinput, PL_regeol)) {
- locinput += 2;
+ if (ANYOF_FOLD_SHARP_S(scan, locinput, PL_regeol)) {
+ locinput += SHARP_S_SKIP;
nextchr = UCHARAT(locinput);
}
else