aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tbl.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2018-12-14 05:18:02 +0000
committerIngo Schwarze <schwarze@openbsd.org>2018-12-14 05:18:02 +0000
commit7a6eb8920bdea2ecc151b308352b2a98699b2350 (patch)
tree9860a766930f3997c413b0f0aecd6ba815b80f25 /tbl.c
parent0ef6626fcc16277d2fefb32e1830dfba3df5defd (diff)
downloadmandoc-7a6eb8920bdea2ecc151b308352b2a98699b2350.tar.gz
mandoc-7a6eb8920bdea2ecc151b308352b2a98699b2350.tar.zst
mandoc-7a6eb8920bdea2ecc151b308352b2a98699b2350.zip
Almost mechanical diff to remove the "struct mparse *" argument
from mandoc_msg(), where it is no longer used. While here, rename mandoc_vmsg() to mandoc_msg() and retire the old version: There is really no point in having another function merely to save "%s" in a few places. Minus 140 lines of code.
Diffstat (limited to 'tbl.c')
-rw-r--r--tbl.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/tbl.c b/tbl.c
index 29ac4fd0..0a8d6c78 100644
--- a/tbl.c
+++ b/tbl.c
@@ -1,4 +1,4 @@
-/* $Id: tbl.c,v 1.44 2018/12/13 02:06:07 schwarze Exp $ */
+/* $Id: tbl.c,v 1.45 2018/12/14 05:18:03 schwarze Exp $ */
/*
* Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2011, 2015 Ingo Schwarze <schwarze@openbsd.org>
@@ -144,8 +144,7 @@ void
tbl_restart(int line, int pos, struct tbl_node *tbl)
{
if (tbl->part == TBL_PART_CDATA)
- mandoc_msg(MANDOCERR_TBLDATA_BLK, tbl->parse,
- line, pos, "T&");
+ mandoc_msg(MANDOCERR_TBLDATA_BLK, line, pos, "T&");
tbl->part = TBL_PART_LAYOUT;
tbl->line = line;
@@ -170,18 +169,15 @@ tbl_end(struct tbl_node *tbl, int still_open)
struct tbl_span *sp;
if (still_open)
- mandoc_msg(MANDOCERR_BLK_NOEND, tbl->parse,
- tbl->line, tbl->pos, "TS");
+ mandoc_msg(MANDOCERR_BLK_NOEND, tbl->line, tbl->pos, "TS");
else if (tbl->part == TBL_PART_CDATA)
- mandoc_msg(MANDOCERR_TBLDATA_BLK, tbl->parse,
- tbl->line, tbl->pos, "TE");
+ mandoc_msg(MANDOCERR_TBLDATA_BLK, tbl->line, tbl->pos, "TE");
sp = tbl->first_span;
while (sp != NULL && sp->first == NULL)
sp = sp->next;
if (sp == NULL) {
- mandoc_msg(MANDOCERR_TBLDATA_NONE, tbl->parse,
- tbl->line, tbl->pos, NULL);
+ mandoc_msg(MANDOCERR_TBLDATA_NONE, tbl->line, tbl->pos, NULL);
return 0;
}
return 1;