1 --- regex2.h.orig 2005-04-19 14:43:24.000000000 -0700
2 +++ regex2.h 2005-04-19 14:41:08.000000000 -0700
23 + for (i = 0; i < cs->nequiv_classes; i++)
24 + /* sadly, we can only deal with single characters from an
25 + * equivalence class */
26 + if (__collate_equiv_match(cs->equiv_classes[i], NULL, 0, ch, NULL, 0, NULL, NULL, loc) > 0)
27 + return (!cs->invert);
29 return (((cs->bmp[ch >> 3] & (1 << (ch & 7))) != 0) ^
32 if (cs->ranges[i].min <= ch && ch <= cs->ranges[i].max)
34 for (i = 0; i < cs->ntypes; i++)
35 - if (iswctype(ch, cs->types[i]))
36 + if (iswctype_l(ch, cs->types[i], loc))
51 + if (ch < NC && cs->nequiv_classes == 0)
52 return (((cs->bmp[ch >> 3] & (1 << (ch & 7))) != 0) ^
55 - return (CHIN1(cs, ch) || CHIN1(cs, towlower(ch)) ||
56 - CHIN1(cs, towupper(ch)));
57 + return (CHIN1(cs, ch, loc) || CHIN1(cs, towlower_l(ch, loc), loc) ||
58 + CHIN1(cs, towupper_l(ch, loc), loc));
60 - return (CHIN1(cs, ch));
61 + return (CHIN1(cs, ch, loc));
66 size_t nsub; /* copy of re_nsub */
67 int backrefs; /* does it use back references? */
68 sopno nplus; /* how deep does it nest +s? */
69 + locale_t loc; /* current locale */
73 -#define OUT (-2) /* a non-character value */
74 -#define ISWORD(c) (iswalnum((uch)(c)) || (c) == '_')
75 +#define OUT (-130) /* a non-character value */
76 +#define ISWORD(c,l) (iswalnum_l((uch)(c), l) || (c) == '_')