summaryrefslogtreecommitdiffstats
path: root/roff.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2011-07-17 12:13:37 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2011-07-17 12:13:37 +0000
commitc65bd324370683e30cc03e16fa78b9ee7059a19e (patch)
treec34b88eba1bd0d2dcc069e123f0195ac92ddbac0 /roff.c
parente1668c2d072b1ff1b0f569174c78d672523280a2 (diff)
downloadmandoc-c65bd324370683e30cc03e16fa78b9ee7059a19e.tar.gz
Add initial `define' support for eqn(7).
This works by iterating over a simple list. It's a slow, auditable early implementation. Data is read (the reading function will be reused) then parsed, then the line re-run if remaining stuff exists. Note this function isn't the same as mandoc_getarg(), as eqn(7) uses a different system for reading quoted strings. This doesn't actually use the defines.
Diffstat (limited to 'roff.c')
-rw-r--r--roff.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/roff.c b/roff.c
index 2d931ca2..04124da3 100644
--- a/roff.c
+++ b/roff.c
@@ -519,18 +519,18 @@ roff_parseln(struct roff *r, int ln, char **bufp,
if (ROFF_CONT != e)
return(e);
if (r->eqn)
- return(eqn_read(&r->eqn, ln, *bufp, pos));
+ return(eqn_read(&r->eqn, ln, *bufp, pos, offs));
if (r->tbl)
return(tbl_read(r->tbl, ln, *bufp, pos));
return(ROFF_CONT);
} else if ( ! ctl) {
if (r->eqn)
- return(eqn_read(&r->eqn, ln, *bufp, pos));
+ return(eqn_read(&r->eqn, ln, *bufp, pos, offs));
if (r->tbl)
return(tbl_read(r->tbl, ln, *bufp, pos));
return(ROFF_CONT);
} else if (r->eqn)
- return(eqn_read(&r->eqn, ln, *bufp, ppos));
+ return(eqn_read(&r->eqn, ln, *bufp, ppos, offs));
/*
* If a scope is open, go to the child handler for that macro,