In order to become able to generate syntax tree nodes on the roff(7)
authorschwarze <schwarze@openbsd.org>
Tue, 20 Oct 2015 02:00:49 +0000 (02:00 +0000)
committerschwarze <schwarze@openbsd.org>
Tue, 20 Oct 2015 02:00:49 +0000 (02:00 +0000)
commit396853b526c3389a2b49063c0b63952f1e01deef
treea14aac13fc173e8a4780664d4f1961a184011ea9
parent7ba9c3eba0ab719782f31ed4f9953cc9e5e68b24
In order to become able to generate syntax tree nodes on the roff(7)
level, validation must be separated from parsing and rewinding.
This first big step moves calling of the mdoc(7) post_*() functions
out of the parser loop into their own mdoc_validate() pass, while
using a new mdoc_state() module to make syntax tree state handling
available to both the parser loop and the validation pass.
12 files changed:
usr.bin/mandoc/Makefile
usr.bin/mandoc/cgi.c
usr.bin/mandoc/libmdoc.h
usr.bin/mandoc/main.c
usr.bin/mandoc/mandocdb.c
usr.bin/mandoc/mdoc.c
usr.bin/mandoc/mdoc.h
usr.bin/mandoc/mdoc_macro.c
usr.bin/mandoc/mdoc_state.c [new file with mode: 0644]
usr.bin/mandoc/mdoc_validate.c
usr.bin/mandoc/roff.c
usr.bin/mandoc/roff_int.h