From 6b6557e8b3b094132c619e3a2e00fe28422fd16f Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sat, 27 Dec 2003 23:40:06 +0000 Subject: Update. 2003-12-23 Paolo Bonzini * posix/regex_internal.c (re_dfa_add_node): Initialize opt_subexp. * posix/regex_internal.h (re_token_type_t): Put OP_DUP_PLUS among the tokens, rather than among the epsilon-transiting nodes. (re_token_t): Add the opt_subexp flag. * posix/regcomp.c (optimize_utf8, calc_first, calc_next, calc_epsdest): Don't consider OP_DUP_PLUS. (mark_opt_subexp, mark_opt_subexp_iter): New functions. (parse_dup_op): Mostly rewritten, lowering OP_DUP_PLUS to OP_DUP_ASTERISK and marking optional subexpressions as such using mark_opt_subexp. * posix/regexec.c (set_regs): Initialize PREV_INDEX_MATCH and pass it to update_regs. (update_regs): Use the PREV_INDEX_MATCH parameter, together with the opt_subexp flag, in order to discard a final empty match of a repeated subexpression. * posix/BOOST.tests: Adjust test vectors. * posix/PCRE.tests: Likewise. * posix/rxspencer/tests: Likewise. 2003-12-17 Paolo Bonzini 2003-12-16 Paolo Bonzini 2003-12-17 Paolo Bonzini 2003-12-16 Jakub Jelinek 2003-04-06 Kaz Kojima 2003-02-20 Paolo Bonzini 2003-01-12 Franz Sirl 2003-01-09 Richard Henderson 2003-01-09 Richard Henderson 2003-01-03 Paul Eggert --- posix/regex_internal.h | 1 + 1 file changed, 1 insertion(+) (limited to 'posix/regex_internal.h') diff --git a/posix/regex_internal.h b/posix/regex_internal.h index 8f11ba7a44..18414a58cc 100644 --- a/posix/regex_internal.h +++ b/posix/regex_internal.h @@ -281,6 +281,7 @@ typedef struct #endif unsigned int constraint : 10; /* context constraint */ unsigned int duplicated : 1; + unsigned int opt_subexp : 1; #ifdef RE_ENABLE_I18N /* These 2 bits can be moved into the union if needed (e.g. if running out of bits; move opr.c to opr.c.c and move the flags to opr.c.flags). */ -- cgit v1.2.3