summaryrefslogtreecommitdiffstats
path: root/mdoc_validate.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2014-07-02 11:43:20 +0000
committerIngo Schwarze <schwarze@openbsd.org>2014-07-02 11:43:20 +0000
commit5974c463fa58c6b119a1cacf57644ad24c66106e (patch)
tree19c2713c0bc8aa1178b68c959993973007c0fa3f /mdoc_validate.c
parent4251a52721ec8ec2c8efc2409d7a08a751793bc5 (diff)
downloadmandoc-5974c463fa58c6b119a1cacf57644ad24c66106e.tar.gz
Clean up warnings related to macros and nesting.
* Hierarchical naming of enum mandocerr items. * Improve the wording to make it comprehensible. * Mention the offending macro. * Garbage collect one chunk of ancient, long unreachable code.
Diffstat (limited to 'mdoc_validate.c')
-rw-r--r--mdoc_validate.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/mdoc_validate.c b/mdoc_validate.c
index a0dad19c..cf00a0f4 100644
--- a/mdoc_validate.c
+++ b/mdoc_validate.c
@@ -591,7 +591,9 @@ pre_display(PRE_ARGS)
break;
if (node)
- mdoc_nmsg(mdoc, n, MANDOCERR_NESTEDDISP);
+ mandoc_vmsg(MANDOCERR_BD_NEST,
+ mdoc->parse, n->line, n->pos,
+ "%s in Bd", mdoc_macronames[n->tok]);
return(1);
}
@@ -1903,7 +1905,7 @@ post_ns(POST_ARGS)
{
if (MDOC_LINE & mdoc->last->flags)
- mdoc_nmsg(mdoc, mdoc->last, MANDOCERR_IGNNS);
+ mdoc_nmsg(mdoc, mdoc->last, MANDOCERR_NS_SKIP);
return(1);
}