diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-01-01 12:59:17 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-01-01 12:59:17 +0000 |
commit | 131de1ee113c08ea304f934c38488baa917375f6 (patch) | |
tree | 5f9c4e393a821b0b372d6dcc62bd76de3c8850da /man_validate.c | |
parent | 98371213a082f1d2d7f5faac716b9818680d3140 (diff) | |
download | mandoc-131de1ee113c08ea304f934c38488baa917375f6.tar.gz |
Add -man support for tables. Like -mdoc, this consists of an
external-facing function man_addspan() (this required shuffling around
the descope routine) and hooks elsewhere.
Also fixed mdoc.c's post-validation of tables.
Diffstat (limited to 'man_validate.c')
-rw-r--r-- | man_validate.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/man_validate.c b/man_validate.c index a7dcac7c..68584688 100644 --- a/man_validate.c +++ b/man_validate.c @@ -117,10 +117,16 @@ man_valid_pre(struct man *m, struct man_node *n) { v_check *cp; - if (MAN_TEXT == n->type) - return(1); - if (MAN_ROOT == n->type) + switch (n->type) { + case (MAN_TEXT): + /* FALLTHROUGH */ + case (MAN_ROOT): + /* FALLTHROUGH */ + case (MAN_TBL): return(1); + default: + break; + } if (NULL == (cp = man_valids[n->tok].pres)) return(1); @@ -145,6 +151,8 @@ man_valid_post(struct man *m) return(check_text(m, m->last)); case (MAN_ROOT): return(check_root(m, m->last)); + case (MAN_TBL): + return(1); default: break; } |