summaryrefslogtreecommitdiffstats
path: root/libman.h
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2014-01-05 20:26:36 +0000
committerIngo Schwarze <schwarze@openbsd.org>2014-01-05 20:26:36 +0000
commit4282adef89d16d5427bc44016843f13275666f72 (patch)
tree94839cb3dd6b9dc512134d1646a420d2e037e0d7 /libman.h
parent5e614e747c24e529f84dbfb18721534f909128e9 (diff)
downloadmandoc-4282adef89d16d5427bc44016843f13275666f72.tar.gz
Add an option -Q (quick) to mandocdb(8)
for accelerated generation of reduced-size databases. Implement this by allowing the parsers to optionally abort the parse sequence after the NAME section. While here, garbage collect the unused void *arg attribute of struct mparse and mparse_alloc() and fix some errors in mandoc(3). This reduces the processing time of mandocdb(8) on /usr/share/man by a factor of 2 and the database size by a factor of 4. However, it still takes 5 times the time and 6 times the space of makewhatis(8), so more work is clearly needed.
Diffstat (limited to 'libman.h')
-rw-r--r--libman.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/libman.h b/libman.h
index 3f3a8262..0ea9cb69 100644
--- a/libman.h
+++ b/libman.h
@@ -24,6 +24,7 @@ enum man_next {
struct man {
struct mparse *parse; /* parse pointer */
+ int quick; /* abort parse early */
int flags; /* parse flags */
#define MAN_HALT (1 << 0) /* badness happened: die */
#define MAN_ELINE (1 << 1) /* Next-line element scope. */