aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tree.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2017-07-08 14:51:04 +0000
committerIngo Schwarze <schwarze@openbsd.org>2017-07-08 14:51:04 +0000
commitcf63fca8357771e9f99c05319bf7ae1d9325cbd8 (patch)
tree283184101587a0e648dd5fcc99c2e2c91519bf49 /tree.c
parent9ef0c733fd442e250894494f24d6a17d1db58500 (diff)
downloadmandoc-cf63fca8357771e9f99c05319bf7ae1d9325cbd8.tar.gz
mandoc-cf63fca8357771e9f99c05319bf7ae1d9325cbd8.tar.zst
mandoc-cf63fca8357771e9f99c05319bf7ae1d9325cbd8.zip
1. Eliminate struct eqn, instead use the existing members
of struct roff_node which is allocated for each equation anyway. 2. Do not keep a list of equation parsers, one parser is enough. Minus fifty lines of code, no functional change.
Diffstat (limited to 'tree.c')
-rw-r--r--tree.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/tree.c b/tree.c
index 126d28c1..7d18b9d9 100644
--- a/tree.c
+++ b/tree.c
@@ -1,4 +1,4 @@
-/* $Id: tree.c,v 1.76 2017/07/07 19:39:30 schwarze Exp $ */
+/* $Id: tree.c,v 1.77 2017/07/08 14:51:05 schwarze Exp $ */
/*
* Copyright (c) 2008, 2009, 2011, 2014 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2013, 2014, 2015, 2017 Ingo Schwarze <schwarze@openbsd.org>
@@ -202,7 +202,7 @@ print_mdoc(const struct roff_node *n, int indent)
}
if (n->eqn)
- print_box(n->eqn->root->first, indent + 4);
+ print_box(n->eqn->first, indent + 4);
if (n->child)
print_mdoc(n->child, indent +
(n->type == ROFFT_BLOCK ? 2 : 4));
@@ -287,7 +287,7 @@ print_man(const struct roff_node *n, int indent)
}
if (n->eqn)
- print_box(n->eqn->root->first, indent + 4);
+ print_box(n->eqn->first, indent + 4);
if (n->child)
print_man(n->child, indent +
(n->type == ROFFT_BLOCK ? 2 : 4));