=================================================================== RCS file: /cvs/mandoc/mandoc.h,v retrieving revision 1.80 retrieving revision 1.83 diff -u -p -r1.80 -r1.83 --- mandoc/mandoc.h 2011/07/17 14:08:49 1.80 +++ mandoc/mandoc.h 2011/07/21 11:34:53 1.83 @@ -1,4 +1,4 @@ -/* $Id: mandoc.h,v 1.80 2011/07/17 14:08:49 kristaps Exp $ */ +/* $Id: mandoc.h,v 1.83 2011/07/21 11:34:53 kristaps Exp $ */ /* * Copyright (c) 2010, 2011 Kristaps Dzonsons * @@ -111,6 +111,7 @@ enum mandocerr { /* related to equations */ MANDOCERR_EQNARGS, /* bad equation macro arguments */ + MANDOCERR_EQNNEST, /* too many nested equation defines */ /* related to tables */ MANDOCERR_TBL, /* bad table syntax */ @@ -276,10 +277,21 @@ 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; - int line; /* invocation line */ + struct eqn_box *root; + int ln; /* invocation line */ int pos; /* invocation position */ };