1. 01 Jan, 2010 1 commit
  2. 29 Dec, 2009 1 commit
    • Jim Meyering's avatar
      update nearly all FSF copyright year lists to include 2009 · 3030c5b5
      Jim Meyering authored
      The files named by the following are exempted:
      
          grep -v '^#' config/srclist.txt|grep -v '^$' \
            | while read src dst; do
                test -f "$dst" && { echo "$dst"; continue; }
                test -d "$dst" || continue
                echo "$dst"/$(basename "$src")
              done > exempt
          git ls-files tests/unictype >> exempt
      
      In the remaining files, convert to all-interval notation if
      - there is already at least one year interval like 2000-2003
      - the file is maintained by me
      - the file is in lib/uni*/, where that style already prevails
      Otherwise, use update-copyright's default.
      3030c5b5
  3. 29 Jan, 2007 1 commit
  4. 27 Nov, 2006 2 commits
  5. 10 Aug, 2006 1 commit
    • Paul Eggert's avatar
      Import the following changes from libc: · ce0f0550
      Paul Eggert authored
      2006-06-02  Jakub Jelinek  <jakub@redhat.com>
      
      * posix/regex_internal.c (re_string_skip_chars): If no character has
      been converted at all, set *last_wc to WEOF.  If mbrtowc failed, set wc
      to the byte which couldn't be converted.
      (re_string_reconstruct): Don't clear valid_raw_len before calling
      re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
      tip_context using re_string_context_at.
      
      2006-05-02  Ulrich Drepper  <drepper@redhat.com>
      
      * posix/regex.h: g++ still cannot handled [restrict].
      
      2006-04-21  Ulrich Drepper  <drepper@redhat.com>
      
      * posix/regex.h: Remove special handling for VMS.
      ce0f0550
  6. 13 Apr, 2006 1 commit
  7. 10 Apr, 2006 1 commit
    • Paul Eggert's avatar
      Merge regex changes from libc, removing some of our · 8335a4d6
      Paul Eggert authored
      POSIX-conformance changes that were rejected and redoing them in a
      less-intrusive way.
      
      * lib/regcomp.c (re_compile_internal, init_dfa):
      Length arg is now size_t, not Idx.  All uses changed.
      (peek_token): Forward decl now says internal_function.
      (__re_error_msgid, __re_error_msgid_idx):
      Now static rather than extern with attribute_hidden.
      (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
      For some reason libc prefers K&R style defns for external functions.
      (regerror) [!defined _LIBC]: Likewise.
      (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
      (seek_collating_symbol_entry, lookup_collation_sequence_value):
      (build_range_exp, build_collating_symbol):
      Use K&R-style defn.
      (re_compile_fastmap): Use '\0' to memset, not 0.
      (utf8_sb_map): Make the calculations more obvious.
      (init_dfa, parse_bracket_exp, build_charclass_op):
      Call calloc and cast result, as glibc does.
      (init_word_char, fetch_token, peek_token, peek_token_bracket):
      (build_range_exp, build_collating_symbol):
      Now internal functions.
      
      * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
      
      * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
      _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
      Don't depend on VMS; depend on __VMS instead, for POSIX
      namespace cleanness.
      (regoff_t): Define to ssize_t, not long int.
      
      Remove the REG_ macros named below.  Instead, make the old names
      (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
      __USE_GNU_REGEX.
      (REG_BACKSLASH_ESCAPE_IN_LISTS):
      (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
      (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
      (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
      (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
      (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
      (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
      (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
      (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
      (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
      (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
      (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
      (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
      (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
      (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
      (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
      (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
      (REG_NREGS):
      Remove.  All uses replaced by the old RE_* names.
      (RE_BACKSLASH_ESCAPE_IN_LISTS):
      (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
      (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
      (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
      (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
      (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
      (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
      (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
      (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
      (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
      (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
      Don't bother having these macros be independent of each others'
      values, since they no longer exist in the POSIX name space.
      
      Rename the following member names back to their old names,
      unless !__USE_GNU_REGEX.  All uses changed back.
      (buffer): Renamed from re_buffer.
      (allocated): Renamed from re_allocated.
      (used): Renamed from re_used.
      (syntax): Renamed from re_syntax.
      (fastmap): Renamed from re_fastmap.
      (translate): Renamed from re_translate.
      (can_be_null): Renamed from re_can_be_null.
      (regs_allocated): Renamed from re_regs_allocated.
      (fastmap_accurate): Renamed from re_fastmap_accurate.
      (no_sub): Renamed from re_no_sub.
      (not_bol): Renamed from re_not_bol.
      (not_eol): Renamed from re_not_eol.
      (newline_anchor): Renamed from re_newline_anchor.
      (num_regs): Renamed from rm_num_regs.
      (start): Renamed from rm_start.
      (end): Renamed from rm_end.
      
      (free_state): Move up a bit.
      
      * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
      #define to be empty.
      (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
      when that is what is intended.
      (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
      (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
      (MAX): New macro.
      (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
      All uses changed back to re_malloc, etc.  It's now the caller's
      responsibility to check for overflow; all callers changed.
      (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
      (re_x2nrealloc): Remove.
      (free_state): Remove decl.
      
      * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
      (re_set_registers, re_exec):
      Use K&R-style defn.
      
      2006-01-31  Roland McGrath  <roland@redhat.com>
      
      * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
      Reported by Mike Frysinger <vapier@gentoo.org>.
      
      2006-01-15  Andreas Jaeger  <aj@suse.de>
      
      [BZ #1950]
      * lib/regex_internal.c (re_string_reconstruct): Adjust for
      build_wcs_upper_buffer change.
      (build_wcs_upper_buffer): Change return type.
      
      2005-12-10  Ulrich Drepper  <drepper@redhat.com>
      
      * lib/regex_internal.h: Include <stdint.h> if available.
      
      2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
      
      * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
      
      2005-10-14  Ulrich Drepper  <drepper@redhat.com>
      
      * lib/regcomp.c: Adjust for changed secondary hash function.
      
      2005-09-30  Ulrich Drepper  <drepper@redhat.com>
      
      * lib/regex.h: Pretty printing.
      Clean up namespace a bit.
      
      2005-09-30  Jakub Jelinek  <jakub@redhat.com>
      
      * lib/regexec.c (update_cur_sifted_state, check_arrival,
      check_arrival_add_next_nodes): Avoid using uninitialized variable.
      
      2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
      	    Ulrich Drepper  <drepper@redhat.com>
      
      [BZ #1302]
      * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses changed.
      (bitset_word_t): Renamed from bitset_word.  All uses changed.
      
      2005-09-22  Ulrich Drepper  <drepper@redhat.com>
      
      [BZ #281]
      * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
      * lib/regcomp.c: Remove unnecessary uses of
      unsigned RE_TRANSLATE_TYPE.
      * lib/regex_internal.h: Likewise.
      * lib/regex_internal.c: Likewise.
      * lib/regexec.c: Likewise.
      Based on a patch by Stepan Kasal <kasal@ucw.cz>.
      
      2005-09-07  Ulrich Drepper  <drepper@redhat.com>
      
      * lib/regexec.c (find_recover_state): Remove unnecessary
      initialization.
      (transit_state_bkref): Make DFA a const pointer.
      (get_subexp): Likewise.
      (check_arrival): Likewise.
      (update_cur_sifted_state): Likewise.
      (re_search_internal): Likewise.
      (prune_impossible_nodes): Likewise.
      (acquire_init_state_context): Likewise.
      (proceed_next_node): Likewise.
      (set_regs): Likewise.
      (free_fail_stack_return): Likewise.
      (check_arrival_expand_ecl): Mark DFA parameter as const.
      (check_arrival_expand_ecl_sub): Likewise.
      (check_subexp_limits): Likewise.
      (sub_epsilon_src_nodes):  Likewise.
      (add_epsilon_src_nodes):  Likewise.
      (merge_state_array): Likewise.
      (update_regs): Likewise.
      (build_trtable): Likewise.
      (sift_states_backward): Mark MCTX parameter as const.
      (build_sifted_states): Likewise.
      (update_cur_sifted_state): Likewise.
      (sift_states_mkref): Likewise.
      (check_arrival_expand_ecl): Mark eclosure as const.
      (check_dst_limits_calc_pos_1): Likewise.
      * lib/regex_internal.h (re_match_context_t): Make dfa a const
      pointer.
      
      2005-09-06  Ulrich Drepper  <drepper@redhat.com>
      
      * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
      (transit_state_sb): Likewise.
      (transit_state_mb): Likewise.
      (sift_states_iter_mb): Likewise.
      (check_arrival_add_next_nodes): Likewise.
      (check_node_accept_bytes): Change first parameter to pointer-to-const.
      [_LIBC] (re_search_2_stub): Use mempcpy.
      
      * lib/regex_internal.c (re_string_reconstruct): Avoid calling
      mbrtowc for very simple UTF-8 case.
      
      * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
      a pointer-to-const.
      (re_acquire_state_context): Likewise.
      * lib/regex_internal.h: Adjust prototypes.
      
      * lib/regex.c: Prevent using C++ compilers.
      
      * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
      (re_acquire_state_context): Likewise.
      8335a4d6
  8. 17 Mar, 2006 1 commit
    • Paul Eggert's avatar
      * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]: · c0174c2f
      Paul Eggert authored
      Typedef to long int, not to off_, as POSIX will likely change
      in that direction.
      
      * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
      no longer needs it.  Instead, check that regoff_t is as least
      as wide as ptrdiff_t.
      
      Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
      so that our regex.h stays compatible with the installed regex.
      This is helpful for installers who configure --without-included-regex.
      Problem reported by Emanuele Giaquinta.
      c0174c2f
  9. 31 Aug, 2005 1 commit
    • Paul Eggert's avatar
      On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the · 28492cce
      Paul Eggert authored
      old glibc regex code mishandles strings longer than 2**31 bytes.
      This patch fixes this when the regex code is used in gnulib
      (i.e., outside glibc).
      
      * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
      governing whether the rest of this patch is active.  By default,
      the macro is disabled and the patch has no effect.
      (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
      (__re_idx_t, __re_size_t, __re_long_size_t): New types.
      (struct re_pattern_buffer, re_search, re_search_2, re_match):
      (re_match_2, re_set_registers): Use the new types.
      * lib/regex_internal.h (Idx, re_hashval_t): New types.
      (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
      New macros.
      (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
      (re_string_context_at, bin_tree_t, re_dfastate_t):
      (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
      (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
      (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
      (re_string_char_size_at, re_string_wchar_at):
      (re_string_elem_size_at):
      Use the new types and macros to port to 64-bit hosts.
      Use unsigned types for internal values, so that the code
      mostly works even for arrays larger than SSIZE_MAX.
      * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
      (search_duplicated_node, calc_eclosure_iter, fetch_number):
      (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
      (build_equiv_class, build_charclass, re_compile_fastmap_iter):
      (free_dfa_content, create_initial_state, optimize_utf8, analyze):
      (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
      (calc_inveclosure, parse_dup_op, build_range_exp):
      (build_collating_symbol, parse_bracket_exp, build_charclass_op):
      (fetch_number, create_token_tree, mark_opt_subexp):
      Likewise.
      * lib/regex_internal.c
      (re_string_construct_common, create_ci_newstate):
      (create_cd_newstate, re_string_allocate, re_string_construct):
      (re_string_realloc_buffers, build_wcs_upper_buffer):
      (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
      (re_string_reconstruct, re_string_peek_byte_case):
      (re_string_fetch_byte_case, re_string_context_at):
      (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
      (re_node_set_init_copy, re_node_set_add_intersect):
      (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
      (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
      (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
      (re_acquire_state, re_acquire_state_context, register_state):
      Likewise.
      * lib/regex.c
      (match_ctx_init, match_ctx_add_entry, search_cur_bkref_entry):
      (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
      (re_search_internal, re_search_2_stub, re_search_stub)
      (re_copy_regs, check_matching, check_halt_state_context, update_regs):
      (push_fail_stack, sift_states_iter_mb, build_sifted_states):
      (update_cur_sifted_state, check_dst_limits):
      (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
      (check_subexp_limits, sift_states_bkref, merge_state_array):
      (check_subexp_matching_top, get_subexp, get_subexp_sub):
      (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
      (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
      (expand_bkref_cache, check_node_accept_bytes):
      (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
      (re_search, re_match_2, re_search_2, prune_impossible_nodes):
      (acquire_init_state_context, check_halt_node_context):
      (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
      (sift_states_backward, clean_state_log_if_needed):
      (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
      (find_recover_state, transit_state_sb, transit_state_mb):
      (transit_state_bkref, build_trtable, match_ctx_clean):
      Likewise.
      * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
      to work around an assumption that REG_MISSING is negative.
      * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
      _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
      and large-file glibc and in 32-bit large-file Solaris.
      * config/srclist.txt: Add glibc bug 1281.
      28492cce
  10. 25 Aug, 2005 1 commit
  11. 24 Aug, 2005 2 commits
    • Paul Eggert's avatar
      [_REGEX_SOURCE]: Define re_fastmap_accurate too; this was · dad0bacf
      Paul Eggert authored
      inadvertently omitted from the previous patch.
      dad0bacf
    • Paul Eggert's avatar
      * config/srclist.txt: · d6103c5e
      Paul Eggert authored
      Remove glibc bug 1233 and add 1236, which supersedes it.
      
      * lib/regex.h: Fix a multitude of POSIX name space violations.
      These changes have an effect only for programs that define
      _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
      do not change anything for programs compiled in the normal way.
      Also, there is no effect on the ABI.
      
      (_REGEX_SOURCE): New macro.
      Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
      defined and _GNU_SOURCE is not; this fixes a name space violation.
      
      Rename the following macros to obey POSIX requirements.
      The old names are still visible as macros if _REGEX_SOURCE is defined.
      (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
      RE_BACKSLASH_ESCAPE_IN_LISTS.
      (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
      (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
      (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
      (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
      (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
      (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
      (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
      (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
      (REG_INTERVALS): renamed from RE_INTERVALS.
      (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
      (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
      (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
      (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
      (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
      (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
      (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
      (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
      RE_UNMATCHED_RIGHT_PAREN_ORD.
      (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
      (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
      (REG_DEBUG): renamed from RE_DEBUG.
      (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
      (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
      unusual, since we can't clash with the POSIX REG_ICASE.
      (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
      (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
      (REG_NO_SUB): renamed from RE_NO_SUB.
      (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
      (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
      (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
      (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
      (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
      (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
      (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
      (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
      (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
      (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
      (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
      (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
      RE_SYNTAX_POSIX_MINIMAL_BASIC.
      (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
      (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
      RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
      (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
      (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
      (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
      (REG_FIXED): Renamed from REGS_FIXED.
      (REG_NREGS): Renamed from RE_NREGS.
      
      (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
      of other REG_* macros, since POSIX says the user is allowed to
      #undef these macros selectively.
      
      (reg_errcode_t): Update comment stating what other tables need
      to be consistent.
      
      Rename the following enum values to obey POSIX requirements.
      The old names are still visible as macros.
      (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
      is not defined, since GNU is supposed to be a superset of POSIX as
      much as possible, and since we want reg_errcode_t to be a signed
      type for implementation consistency.
      (_REG_NOERROR): Renamed from REG_NOERROR.
      (_REG_NOMATCH): Renamed from REG_NOMATCH.
      (_REG_BADPAT): Renamed from REG_BADPAT.
      (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
      (_REG_ECTYPE): Renamed from REG_ECTYPE.
      (_REG_EESCAPE): Renamed from REG_EESCAPE.
      (_REG_ESUBREG): Renamed from REG_ESUBREG.
      (_REG_EBRACK): Renamed from REG_EBRACK.
      (_REG_EPAREN): Renamed from REG_EPAREN.
      (_REG_EBRACE): Renamed from REG_EBRACE.
      (_REG_BADBR): Renamed from REG_BADBR.
      (_REG_ERANGE): Renamed from REG_ERANGE.
      (_REG_ESPACE): Renamed from REG_ESPACE.
      (_REG_BADRPT): Renamed from REG_BADRPT.
      (_REG_EEND): Renamed from REG_EEND.
      (_REG_ESIZE): Renamed from REG_ESIZE.
      (_REG_ERPAREN): Renamed from REG_ERPAREN.
      (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
      (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
      (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
      (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
      
      (_REG_RE_NAME, _REG_RM_NAME): New macros.
      (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
      changed.  But support the old name if the new one is not defined
      and if _REGEX_SOURCE.
      
      Change the following member names in struct re_pattern_buffer.
      The old names are still supported if !_REGEX_SOURCE.
      The new names are always supported, regardless of _REGEX_SOURCE.
      (re_buffer): Renamed from buffer.
      (re_allocated): Renamed from allocated.
      (re_used): Renamed from used.
      (re_syntax): Renamed from syntax.
      (re_fastmap): Renamed from fastmap.
      (re_translate): Renamed from translate.
      (re_can_be_null): Renamed from can_be_null.
      (re_regs_allocated): Renamed from regs_allocated.
      (re_fastmap_accurate): Renamed from fastmap_accurate.
      (re_no_sub): Renamed from no_sub.
      (re_not_bol): Renamed from not_bol.
      (re_not_eol): Renamed from not_eol.
      (re_newline_anchor): Renamed from newline_anchor.
      
      Change the following member names in struct re_registers.
      The old names are still supported if !_REGEX_SOURCE.
      The new names are always supported, regardless of _REGEX_SOURCE.
      (rm_num_regs): Renamed from num_regs.
      (rm_start): Renamed from start.
      (rm_end): Renamed from end.
      
      (re_set_syntax, re_compile_pattern, re_compile_fastmap):
      (re_search, re_search_2, re_match, re_match_2, re_set_registers):
      Prepend __ to parameter names.
      d6103c5e
  12. 23 Aug, 2005 2 commits
  13. 20 Aug, 2005 1 commit
    • Paul Eggert's avatar
      * config/srclist.txt: Add glibc bugs 1220, 1221, 1222. · 087e9e5b
      Paul Eggert authored
      * lib/regcomp.c:
      (re_compile_pattern, re_set_syntax, re_compile_fastmap):
      (re_compile_fastmap_iter, regcomp, regerror, regfree):
      (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
      (create_initial_state, optimize_utf8, analyze, postorder, preorder):
      (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
      (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
      (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
      (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
      (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
      (build_range_exp, build_collating_symbol, parse_bracket_exp):
      (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
      (build_charclass, build_charclass_op, fetch_number, create_tree):
      (create_token_tree, mark_opt_subexp, duplicate_tree):
      Use prototypes rather than old-style definitions.
      * lib/regex_internal.c:
      (re_string_allocate, re_string_construct, re_string_realloc_buffers):
      (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
      (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
      (re_string_reconstruct, re_string_peek_byte_case):
      (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
      (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
      (re_node_set_init_copy, re_node_set_add_intersect):
      (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
      (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
      (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
      (re_acquire_state, re_acquire_state_context, register_state):
      (create_ci_newstate, create_cd_newstate, free_state):
      Likewise.
      * lib/regexec.c (regexec, re_match, re_search, re_match_2, re_search_2):
      (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
      (re_search_internal, prune_impossible_nodes):
      (acquire_init_state_context, check_matching, static):
      (check_halt_node_context, check_halt_state_context, proceed_next_node):
      (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
      (update_regs, sift_states_backward, build_sifted_states):
      (clean_state_log_if_needed, merge_state_array):
      (update_cur_sifted_state, add_epsilon_src_nodes):
      (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
      (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
      (sift_states_iter_mb, transit_state, merge_state_with_log, static):
      (find_recover_state, check_subexp_matching_top, transit_state_mb):
      (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
      (check_arrival, check_arrival_add_next_nodes):
      (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
      (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
      (check_node_accept_bytes, check_node_accept, extend_buffers):
      (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
      (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
      (sift_ctx_init):
      Likewise.
      
      * lib/regex_internal.h:
      (re_string_allocate, re_string_construct, re_string_reconstruct):
      (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
      (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
      (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
      (re_string_context_at, re_string_peek_byte_case):
      (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
      is defined, since we now use prototypes always.
      
      * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
      C89 or better.  All uses removed.
      087e9e5b
  14. 18 Aug, 2005 1 commit
  15. 16 Aug, 2005 1 commit
  16. 07 Jul, 2005 1 commit
    • Paul Eggert's avatar
      * modules/regex (Files): Add lib/regex_internal.c, · 151e40bb
      Paul Eggert authored
      lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
      (Depends-on): Add extensions.
      (Makefile.am): Remove lib_SOURCES; now done by m4 code.
      * config/srclist.txt: Add regcomp.c, regex.c, regex.h, regex_internal.c,
      regexec.c.
      Add regex_internal.h too, but as a comment, since the libc version
      is currently broken in gnulib mode.
      * lib/regex.c, lib/regex.h: Sync from libc.
      * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h, lib/regexec.c:
      New files, synced from libc, except that regex_internal.h
      currently has a small porting fix.
      * m4/regex.m4: Adjust to new libc regex implementation.
      (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
      all the .c and .h parts of (the new) regex.
      Quote the m4 stuff better.
      Check for RE_ICASE bug of old gnulib.
      Check for REG_STARTEND of recent libc.
      Rename local variables from jm_* to gl_*.
      Quote operand of "test -f".
      Say "recent enough" version of libc, not "version 2".
      (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
      prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
      Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
      Remove check for btowc, isascii.
      Require AM_LANGINFO_CODESET.
      151e40bb
  17. 15 May, 2005 1 commit
    • Paul Eggert's avatar
      Sync from coreutils. · 6ef9a073
      Paul Eggert authored
      * modules/yesno (Depends-on): Add getline.
      * gethrxtime.c, gethrxtime.h, getpass.h, mountlist.h, path-concat.c,
      regex.h, strtoll.c, unlocked-io.h, xtime.h:
      White space changes only.
      * makepath.c (make_path): Port to hosts where leading "//" is special.
      * yesno.c: Include getline.h, not ctype.h.
      (yesno): Don't remove leading white space; POSIX doesn't allow it.
      Use getline to remove arbitrary restriction on response length.
      6ef9a073
  18. 14 May, 2005 1 commit
  19. 10 Sep, 2003 1 commit
  20. 17 Aug, 2003 1 commit
  21. 12 Aug, 2003 1 commit
  22. 10 Aug, 2003 1 commit
  23. 09 Aug, 2003 1 commit
  24. 18 Apr, 2003 1 commit
  25. 25 Nov, 2002 1 commit
  26. 15 Dec, 2001 1 commit
  27. 12 Aug, 2001 1 commit
  28. 02 Apr, 2001 1 commit
  29. 29 Oct, 2000 1 commit
  30. 28 Oct, 2000 1 commit
  31. 04 May, 2000 1 commit
  32. 13 Jan, 1999 1 commit
  33. 07 Aug, 1998 1 commit
  34. 23 Mar, 1998 1 commit
  35. 26 Jul, 1997 1 commit
  36. 15 Jul, 1996 1 commit
  37. 19 Oct, 1995 1 commit