diff options
author | Ulrich Drepper <drepper@redhat.com> | 2003-11-16 07:14:28 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2003-11-16 07:14:28 +0000 |
commit | f0c7c524bb92cdc42cc4e0f7ba1ddda865a4494c (patch) | |
tree | f06d459ac9d5a2d7c02591cd5375dd7ad6ff7a1e /posix/regcomp.c | |
parent | 2def87644d44b41bb908d4ed150a110d4d9399ea (diff) | |
download | glibc-f0c7c524bb92cdc42cc4e0f7ba1ddda865a4494c.tar glibc-f0c7c524bb92cdc42cc4e0f7ba1ddda865a4494c.tar.gz glibc-f0c7c524bb92cdc42cc4e0f7ba1ddda865a4494c.tar.bz2 glibc-f0c7c524bb92cdc42cc4e0f7ba1ddda865a4494c.zip |
Update.
* posix/regex_internal.h: Add forward declaration of re_dfa_t.
Replace last two parameters of re_string_allocate and
re_string_construct with pointer to DFA.
(re_dfa_t): Add map_notascii field.
* posix/regcomp.c (re_compile_internal): Add call of
re_string_construct.
(init_dfa): Initialize mpa_notascii.
* posix/regex_internal.c: Adjust definitions of re_string_allocate
and re_string_construct.
Pass DFA to re_string_construct. Adjust definition. Initialize
map_notascii field.
(build_wcs_upper_buffer): If map_notascii is zero use simplfied
method to map ASCII values to upper case.
* posix/regex.c: Include localeinfo.h.
* posix/regexec.c: Adjust call of re_string_allocate.
* locale/langinfo.h: Add _NL_CTYPE_MAP_TO_NONASCII.
* locale/localeinfo.h (LIMAGIC): Change value.
* locale/categories.def. Add entry for _NL_CTYPE_MAP_TO_NONASCII.
* locale/C-ctype.h: Likewise.
* locale/programs/ld-ctype.c: Compute whether any mapping maps from
ASCII to non-ASCII value. Write out that value.
Diffstat (limited to 'posix/regcomp.c')
-rw-r--r-- | posix/regcomp.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/posix/regcomp.c b/posix/regcomp.c index 9f56b389df..68ce551c3a 100644 --- a/posix/regcomp.c +++ b/posix/regcomp.c @@ -748,8 +748,7 @@ re_compile_internal (preg, pattern, length, syntax) #endif err = re_string_construct (®exp, pattern, length, preg->translate, - syntax & RE_ICASE, dfa->mb_cur_max, - dfa->is_utf8); + syntax & RE_ICASE, dfa); if (BE (err != REG_NOERROR, 0)) { re_free (dfa); @@ -828,6 +827,8 @@ init_dfa (dfa, pat_len) if (dfa->mb_cur_max > 1 && strcmp (_NL_CURRENT (LC_CTYPE, _NL_CTYPE_CODESET_NAME), "UTF-8") == 0) dfa->is_utf8 = 1; + dfa->map_notascii = (_NL_CURRENT_WORD (LC_CTYPE, _NL_CTYPE_MAP_TO_NONASCII) + != 0); #endif if (BE (dfa->nodes == NULL || dfa->state_table == NULL |