diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2005-07-08 17:58:35 +0000 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2005-07-08 17:58:35 +0000 |
commit | 64890758cff979d28a3618fe7b3c5df83be53b25 (patch) | |
tree | 32d58ffdf530757ec057ee268c0a6097783b7f49 /lib | |
parent | 0e5aafc45a9c139fce58c8338e54e51a719bbd6c (diff) | |
download | coreutils-64890758cff979d28a3618fe7b3c5df83be53b25.tar.xz |
(init_dfa, build_range_exp): Store __btowc value
in wint_t, not wchar_t. Remove now-unnecessary cast.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ChangeLog | 6 | ||||
-rw-r--r-- | lib/regcomp.c | 7 |
2 files changed, 10 insertions, 3 deletions
diff --git a/lib/ChangeLog b/lib/ChangeLog index 762d44155..b84f78977 100644 --- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,9 @@ +2005-07-08 Eric Blake <ebb9@byu.net> (tiny change) + and Paul Eggert <eggert@cs.ucla.edu> + + * regcomp.c (init_dfa, build_range_exp): Store __btowc value + in wint_t, not wchar_t. Remove now-unnecessary cast. + 2005-07-07 Paul Eggert <eggert@cs.ucla.edu> Switch to Isamu Hasegawa's implementation of regex, which is diff --git a/lib/regcomp.c b/lib/regcomp.c index 9feac9fc4..ea9393405 100644 --- a/lib/regcomp.c +++ b/lib/regcomp.c @@ -917,11 +917,11 @@ init_dfa (dfa, pat_len) for (i = 0, ch = 0; i < BITSET_UINTS; ++i) for (j = 0; j < UINT_BITS; ++j, ++ch) { - wchar_t wch = __btowc (ch); + wint_t wch = __btowc (ch); if (wch != WEOF) dfa->sb_char[i] |= 1 << j; # ifndef _LIBC - if (isascii (ch) && wch != (wchar_t) ch) + if (isascii (ch) && wch != ch) dfa->map_notascii = 1; # endif } @@ -2682,7 +2682,8 @@ build_range_exp (sbcset, start_elem, end_elem) # ifdef RE_ENABLE_I18N { - wchar_t wc, start_wc, end_wc; + wchar_t wc; + wint_t start_wc, end_wc; wchar_t cmp_buf[6] = {L'\0', L'\0', L'\0', L'\0', L'\0', L'\0'}; start_ch = ((start_elem->type == SB_CHAR) ? start_elem->opr.ch |