aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/mdoc_validate.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2014-07-02 13:10:45 +0000
committerIngo Schwarze <schwarze@openbsd.org>2014-07-02 13:10:45 +0000
commit3eba010f0f31a85978d61e0b11e8da1c4933dac5 (patch)
tree3bf42092313dcb8fe6c4ba4b3c28495c876d4c14 /mdoc_validate.c
parent494bb76472a464f4c16c06824742893732fe349e (diff)
downloadmandoc-3eba010f0f31a85978d61e0b11e8da1c4933dac5.tar.gz
mandoc-3eba010f0f31a85978d61e0b11e8da1c4933dac5.tar.zst
mandoc-3eba010f0f31a85978d61e0b11e8da1c4933dac5.zip
Disentangle the MANDOCERR_CHILD message, which reported three
completely different things, into three distinct messages. Also mention the macro names we are talking about.
Diffstat (limited to 'mdoc_validate.c')
-rw-r--r--mdoc_validate.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/mdoc_validate.c b/mdoc_validate.c
index 1aa743da..52bd51b2 100644
--- a/mdoc_validate.c
+++ b/mdoc_validate.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc_validate.c,v 1.220 2014/07/02 11:43:20 schwarze Exp $ */
+/* $Id: mdoc_validate.c,v 1.221 2014/07/02 13:10:45 schwarze Exp $ */
/*
* Copyright (c) 2008-2012 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2010-2014 Ingo Schwarze <schwarze@openbsd.org>
@@ -1117,7 +1117,8 @@ post_vt(POST_ARGS)
for (n = mdoc->last->child; n; n = n->next)
if (MDOC_TEXT != n->type)
- mdoc_nmsg(mdoc, n, MANDOCERR_CHILD);
+ mandoc_msg(MANDOCERR_VT_CHILD, mdoc->parse,
+ n->line, n->pos, mdoc_macronames[n->tok]);
return(1);
}
@@ -1613,7 +1614,9 @@ post_bl(POST_ARGS)
continue;
}
- mdoc_nmsg(mdoc, nchild, MANDOCERR_CHILD);
+ mandoc_msg(MANDOCERR_BL_MOVE, mdoc->parse,
+ nchild->line, nchild->pos,
+ mdoc_macronames[nchild->tok]);
/*
* Move the node out of the Bl block.
@@ -1782,7 +1785,8 @@ post_rs(POST_ARGS)
}
next = nn->next;
- mdoc_nmsg(mdoc, nn, MANDOCERR_CHILD);
+ mandoc_msg(MANDOCERR_RS_SKIP, mdoc->parse,
+ nn->line, nn->pos, mdoc_macronames[nn->tok]);
mdoc_node_delete(mdoc, nn);
}