diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2015-07-08 19:59:03 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2015-07-08 19:59:03 +0300 |
commit | bcaab97477a3718e3197a59f4bef5a7e0a5fb84a (patch) | |
tree | a95e30ec87f82df42dcd80aa9fe3a88fbc2098be /dfa.h | |
parent | 6489e5d9ef2969e955db4b7a2a1beac1d66f76f8 (diff) | |
parent | 2eee1b8e780b00062b2a8eef649ebbebaba4682c (diff) | |
download | egawk-bcaab97477a3718e3197a59f4bef5a7e0a5fb84a.tar.gz egawk-bcaab97477a3718e3197a59f4bef5a7e0a5fb84a.tar.bz2 egawk-bcaab97477a3718e3197a59f4bef5a7e0a5fb84a.zip |
Merge branch 'gawk-4.1-stable'
Diffstat (limited to 'dfa.h')
-rw-r--r-- | dfa.h | 12 |
1 files changed, 8 insertions, 4 deletions
@@ -26,6 +26,8 @@ #endif /* HAVE_STDBOOL_H */ #include <stddef.h> +#define _GL_ATTRIBUTE_MALLOC + /* Element of a list of strings, at least one of which is known to appear in any R.E. matching the DFA. */ struct dfamust @@ -34,7 +36,6 @@ struct dfamust bool begline; bool endline; char *must; - struct dfamust *next; }; /* The dfa structure. It is completely opaque. */ @@ -45,10 +46,13 @@ struct dfa; /* Allocate a struct dfa. The struct dfa is completely opaque. The returned pointer should be passed directly to free() after calling dfafree() on it. */ -extern struct dfa *dfaalloc (void); +extern struct dfa *dfaalloc (void) _GL_ATTRIBUTE_MALLOC; + +/* Build and return the struct dfamust from the given struct dfa. */ +extern struct dfamust *dfamust (struct dfa const *); -/* Return the dfamusts associated with a dfa. */ -extern struct dfamust *dfamusts (struct dfa const *); +/* Free the storage held by the components of a struct dfamust. */ +extern void dfamustfree (struct dfamust *); /* dfasyntax() takes three arguments; the first sets the syntax bits described earlier in this file, the second sets the case-folding flag, and the |