CVSROOT: /cvs Module name: src Changes by: schwa...@cvs.openbsd.org 2018/08/23 08:16:12
Modified files: share/man/man7 : roff.7 usr.bin/mandoc : libmandoc.h mandoc.1 mandoc.h read.c roff.c regress/usr.bin/mandoc/roff: Makefile regress/usr.bin/mandoc/roff/de: infinite.in infinite.out_ascii infinite.out_lint Added files: regress/usr.bin/mandoc/roff/return: Makefile basic.in basic.out_ascii basic.out_lint regress/usr.bin/mandoc/roff/shift: Makefile bad.in bad.out_ascii bad.out_lint basic.in basic.out_ascii Log message: Implement the roff(7) .shift and .return requests, for example used by groff_hdtbl(7) and groff_mom(7). Also correctly interpolate arguments during nested macro execution even after .shift and .return, implemented using a stack of argument arrays. Note that only read.c, but not roff.c can detect the end of a macro execution, and the existence of .shift implies that arguments cannot be interpolated up front, so unfortunately, this includes a partial revert of roff.c rev. 1.209, moving argument interpolation back into the function roff_res().