about summary refs log tree commit diff
path: root/posix/regex_internal.h
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-12-06 03:03:01 +0000
committerUlrich Drepper <drepper@redhat.com>2004-12-06 03:03:01 +0000
commitd8f73de86a4073070f5b626dc66a330d1597df88 (patch)
tree74a1fcfbef42a632c67f67f79677c2992955cea4 /posix/regex_internal.h
parentae73c6c1204c1693abbbd4f50e2b4bae1394e9e4 (diff)
downloadglibc-d8f73de86a4073070f5b626dc66a330d1597df88.tar.gz
glibc-d8f73de86a4073070f5b626dc66a330d1597df88.tar.xz
glibc-d8f73de86a4073070f5b626dc66a330d1597df88.zip
Update.
2004-12-01  Paolo Bonzini  <bonzini@gnu.org>

	* posix/regcomp.c (free_dfa_content, init_dfa): Remove
	references to re_dfa_t's subexps field.
	(parse_sub_exp, parse_expression): Do not use it.  Use
	completed_bkref_map instead.
	(create_initial_state, peek_token): Store a backreference \N
	with opr.idx = N-1.
	* posix/regexec.c (proceed_next_node, check_dst_limits, get_subexp):
	Likewise.
	(check_subexp_limits): Remove useless condition.
	* posix/regex_internal.h (re_subexp_t): Remove.
	(re_dfa_t): Remove subexps and subexps_alloc field, add
	completed_bkref_map.
Diffstat (limited to 'posix/regex_internal.h')
-rw-r--r--posix/regex_internal.h12
1 files changed, 3 insertions, 9 deletions
diff --git a/posix/regex_internal.h b/posix/regex_internal.h
index 703d409eb8..1345067a89 100644
--- a/posix/regex_internal.h
+++ b/posix/regex_internal.h
@@ -496,13 +496,6 @@ struct re_dfastate_t
 };
 typedef struct re_dfastate_t re_dfastate_t;
 
-typedef struct
-{
-  /* start <= node < end  */
-  int start;
-  int end;
-} re_subexp_t;
-
 struct re_state_table_entry
 {
   int num;
@@ -607,7 +600,6 @@ struct re_fail_stack_t
 
 struct re_dfa_t
 {
-  re_subexp_t *subexps;
   re_token_t *nodes;
   int nodes_alloc;
   int nodes_len;
@@ -627,13 +619,15 @@ struct re_dfa_t
   int str_tree_storage_idx;
 
   /* number of subexpressions `re_nsub' is in regex_t.  */
-  int subexps_alloc;
   unsigned int state_hash_mask;
   int states_alloc;
   int init_node;
   int nbackref; /* The number of backreference in this dfa.  */
+
   /* Bitmap expressing which backreference is used.  */
   unsigned int used_bkref_map;
+  unsigned int completed_bkref_map;
+
   unsigned int has_plural_match : 1;
   /* If this dfa has "multibyte node", which is a backreference or
      a node which can accept multibyte character or multi character