summaryrefslogtreecommitdiff
path: root/lib/dfa.h
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2019-12-11 13:40:01 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2019-12-11 15:09:38 -0800
commit360cbd3b17a314807e808626e100ef47dcf4d162 (patch)
tree2dc2500b8ba8a53e96f8cbc484ccf9898ea3de86 /lib/dfa.h
parentac92492294ca52fe2596f6353a3fe2800052f676 (diff)
downloadgnulib-360cbd3b17a314807e808626e100ef47dcf4d162.tar.gz
dfa: update commentary for previous change
* NEWS: Mention the change. * lib/dfa.c, lib/dfa.h (dfaparse, dfamust, dfacomp): Update comments.
Diffstat (limited to 'lib/dfa.h')
-rw-r--r--lib/dfa.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/lib/dfa.h b/lib/dfa.h
index 221f7d172a..bf87703e8b 100644
--- a/lib/dfa.h
+++ b/lib/dfa.h
@@ -65,18 +65,20 @@ enum
extern void dfasyntax (struct dfa *, struct localeinfo const *,
reg_syntax_t, int);
-/* Build and return the struct dfamust from the given struct dfa. */
+/* Parse the given string of given length into the given struct dfa. */
+extern void dfaparse (char const *, size_t, struct dfa *);
+
+/* Allocate and return a struct dfamust from a struct dfa that was
+ initialized by dfaparse and not yet given to dfacomp. */
extern struct dfamust *dfamust (struct dfa const *);
/* Free the storage held by the components of a struct dfamust. */
extern void dfamustfree (struct dfamust *);
-/* Parse the given string of given length into the given struct dfa. */
-extern void dfaparse (char const *, size_t, struct dfa *);
-
/* Compile the given string of the given length into the given struct dfa.
- Final argument is a flag specifying whether to build a searching or an
- exact matcher. */
+ The last argument says whether to build a searching or an exact matcher.
+ A null first argument means the struct dfa has already been
+ initialized by dfaparse; the second argument is ignored. */
extern void dfacomp (char const *, size_t, struct dfa *, bool);
/* Search through a buffer looking for a match to the given struct dfa.