aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/mandoc.h
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2011-07-21 11:34:53 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2011-07-21 11:34:53 +0000
commit175c51d9a38aa43801777db95c54f0d7abf91092 (patch)
tree93774c3c3bba8e5ca272cc359c8d6ea63532fed9 /mandoc.h
parentfee8aca887653490f8c052e474d2a620140e741d (diff)
downloadmandoc-175c51d9a38aa43801777db95c54f0d7abf91092.tar.gz
mandoc-175c51d9a38aa43801777db95c54f0d7abf91092.tar.zst
mandoc-175c51d9a38aa43801777db95c54f0d7abf91092.zip
Flip eqn into using parsed nodes. I've temporarily disabled printing
these in the front-ends except for -Ttree, which will display the parsed tree. While here, fix that quoted strings aren't scanned for replacement parts.
Diffstat (limited to 'mandoc.h')
-rw-r--r--mandoc.h17
1 files changed, 14 insertions, 3 deletions
diff --git a/mandoc.h b/mandoc.h
index a832310a..7c46c763 100644
--- a/mandoc.h
+++ b/mandoc.h
@@ -1,4 +1,4 @@
-/* $Id: mandoc.h,v 1.82 2011/07/21 10:24:35 kristaps Exp $ */
+/* $Id: mandoc.h,v 1.83 2011/07/21 11:34:53 kristaps Exp $ */
/*
* Copyright (c) 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -277,9 +277,20 @@ struct tbl_span {
struct tbl_span *next;
};
+enum eqn_boxt {
+ EQN_ROOT,
+ EQN_TEXT
+};
+
+struct eqn_box {
+ enum eqn_boxt type;
+ struct eqn_box *child;
+ struct eqn_box *next;
+ char *text;
+};
+
struct eqn {
- size_t sz;
- char *data;
+ struct eqn_box *root;
int ln; /* invocation line */
int pos; /* invocation position */
};