diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2020-03-13 15:32:28 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2020-03-13 15:32:28 +0000 |
commit | 42d5f8ddfdcc19abca690eba6b3c1bc230e43079 (patch) | |
tree | 9371c93d722eb8a93f7723cefc34599d43b0cffb /regress/mdoc | |
parent | 65d9edcb60637a2dacc525de8389743979e31e41 (diff) | |
download | mandoc-42d5f8ddfdcc19abca690eba6b3c1bc230e43079.tar.gz |
Split tagging into a validation part including prioritization
in tag.{h,c} and {mdoc,man}_validate.c
and into a formatting part including command line argument checking
in term_tag.{h,c}, html.c, and {mdoc|man}_{term|html}.c.
Immediate functional benefits include:
* Improved prioritization of automatic tags for .Em and .Sy.
* Avoiding bogus automatic tags when .Em, .Fn, or .Sy are explicitly tagged.
* Explicit tagging of .Er and .Fl now works in HTML output.
* Automatic tagging of .IP and .TP now works in HTML output.
But mainly, this patch provides clean earth to build further improvements on.
Technical changes:
* Main program: Write a tag file for ASCII and UTF-8 output only.
* All formatters: There is no more need to delay writing the tags.
* mdoc(7)+man(7) formatters: No more need for elaborate syntax tree inspection.
* HTML formatter: If available, use the "string" attribute as the tag.
* HTML formatter: New function to write permalinks, to reduce code duplication.
Style cleanup in the vicinity while here:
* mdoc(7) terminal formatter: To set up bold font for children,
defer to termp_bold_pre() rather than calling term_fontpush() manually.
* mdoc(7) terminal formatter: Garbage collect some duplicate functions.
* mdoc(7) HTML formatter: Unify <code> handling, delete redundant functions.
* Where possible, use switch statements rather than if cascades.
* Get rid of some more Yoda notation.
The necessity for such changes was first discussed with kn@, but i didn't
bother him with a request to review the resulting -673/+782 line patch.
Diffstat (limited to 'regress/mdoc')
81 files changed, 1078 insertions, 26 deletions
diff --git a/regress/mdoc/Cm/Makefile b/regress/mdoc/Cm/Makefile index 4b7066ec..7bc3fc20 100644 --- a/regress/mdoc/Cm/Makefile +++ b/regress/mdoc/Cm/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.3 2014/07/02 20:18:42 schwarze Exp $ +# $OpenBSD: Makefile,v 1.7 2020/03/13 00:31:05 schwarze Exp $ -REGRESS_TARGETS = basic font noarg punct +REGRESS_TARGETS = basic font noarg punct tag +TAG_TARGETS = tag LINT_TARGETS = noarg +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Cm/tag.in b/regress/mdoc/Cm/tag.in new file mode 100644 index 00000000..2fe7d1e3 --- /dev/null +++ b/regress/mdoc/Cm/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:05 schwarze Exp $ +.Dd $Mdocdate$ +.Dt CM-TAG 1 +.Os +.Sh NAME +.Nm Cm-tag +.Nd tagging of command modifier macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Cm one | two +text +.It Xo +.Cm three +.Xc +text +.El +.Tg +.Cm four +.Pp +ENDTEST diff --git a/regress/mdoc/Cm/tag.out_ascii b/regress/mdoc/Cm/tag.out_ascii new file mode 100644 index 00000000..071408c7 --- /dev/null +++ b/regress/mdoc/Cm/tag.out_ascii @@ -0,0 +1,17 @@ +CM-TAG(1) General Commands Manual CM-TAG(1) + +NNAAMMEE + CCmm--ttaagg - tagging of command modifier macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + oonnee | ttwwoo + text + + tthhrreeee text + ffoouurr + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Cm/tag.out_html b/regress/mdoc/Cm/tag.out_html new file mode 100644 index 00000000..a140fe3e --- /dev/null +++ b/regress/mdoc/Cm/tag.out_html @@ -0,0 +1,9 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><code class="Cm" id="one">one</code></a> + | + <a class="permalink" href="#two"><code class="Cm" id="two">two</code></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><code class="Cm" id="three">three</code></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><code class="Cm" id="four">four</code></a> diff --git a/regress/mdoc/Cm/tag.out_markdown b/regress/mdoc/Cm/tag.out_markdown new file mode 100644 index 00000000..893a8fe5 --- /dev/null +++ b/regress/mdoc/Cm/tag.out_markdown @@ -0,0 +1,23 @@ +CM-TAG(1) - General Commands Manual + +# NAME + +**Cm-tag** - tagging of command modifier macros + +# DESCRIPTION + +BEGINTEST + +**one** | **two** + +> text + +**three** + +> text + +**four** + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Cm/tag.out_tag b/regress/mdoc/Cm/tag.out_tag new file mode 100644 index 00000000..94f0cfb2 --- /dev/null +++ b/regress/mdoc/Cm/tag.out_tag @@ -0,0 +1,4 @@ +one 9 +two 9 +three 12 +four 13 diff --git a/regress/mdoc/Dv/Makefile b/regress/mdoc/Dv/Makefile index cfe3ad0b..979e1826 100644 --- a/regress/mdoc/Dv/Makefile +++ b/regress/mdoc/Dv/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.2 2014/07/02 20:18:42 schwarze Exp $ +# $OpenBSD: Makefile,v 1.5 2020/03/13 00:31:05 schwarze Exp $ -REGRESS_TARGETS = font noarg +REGRESS_TARGETS = font noarg tag +TAG_TARGETS = tag LINT_TARGETS = noarg +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Dv/tag.in b/regress/mdoc/Dv/tag.in new file mode 100644 index 00000000..60d2716b --- /dev/null +++ b/regress/mdoc/Dv/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:05 schwarze Exp $ +.Dd $Mdocdate$ +.Dt DV-TAG 1 +.Os +.Sh NAME +.Nm Dv-tag +.Nd tagging of defined variable macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Dv one | two +text +.It Xo +.Dv three +.Xc +text +.El +.Tg +.Dv four +.Pp +ENDTEST diff --git a/regress/mdoc/Dv/tag.out_ascii b/regress/mdoc/Dv/tag.out_ascii new file mode 100644 index 00000000..119e3509 --- /dev/null +++ b/regress/mdoc/Dv/tag.out_ascii @@ -0,0 +1,17 @@ +DV-TAG(1) General Commands Manual DV-TAG(1) + +NNAAMMEE + DDvv--ttaagg - tagging of defined variable macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + one | two + text + + three text + four + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Dv/tag.out_html b/regress/mdoc/Dv/tag.out_html new file mode 100644 index 00000000..cee78340 --- /dev/null +++ b/regress/mdoc/Dv/tag.out_html @@ -0,0 +1,9 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><code class="Dv" id="one">one</code></a> + | + <a class="permalink" href="#two"><code class="Dv" id="two">two</code></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><code class="Dv" id="three">three</code></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><code class="Dv" id="four">four</code></a> diff --git a/regress/mdoc/Dv/tag.out_markdown b/regress/mdoc/Dv/tag.out_markdown new file mode 100644 index 00000000..29b454bb --- /dev/null +++ b/regress/mdoc/Dv/tag.out_markdown @@ -0,0 +1,23 @@ +DV-TAG(1) - General Commands Manual + +# NAME + +**Dv-tag** - tagging of defined variable macros + +# DESCRIPTION + +BEGINTEST + +`one` | `two` + +> text + +`three` + +> text + +`four` + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Dv/tag.out_tag b/regress/mdoc/Dv/tag.out_tag new file mode 100644 index 00000000..94f0cfb2 --- /dev/null +++ b/regress/mdoc/Dv/tag.out_tag @@ -0,0 +1,4 @@ +one 9 +two 9 +three 12 +four 13 diff --git a/regress/mdoc/Em/Makefile b/regress/mdoc/Em/Makefile index 13de4337..2b500444 100644 --- a/regress/mdoc/Em/Makefile +++ b/regress/mdoc/Em/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.3 2014/11/17 06:44:35 schwarze Exp $ +# $OpenBSD: Makefile,v 1.6 2020/03/13 00:31:05 schwarze Exp $ -REGRESS_TARGETS = font noarg punct +REGRESS_TARGETS = font noarg punct tag +TAG_TARGETS = tag LINT_TARGETS = noarg punct +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Em/tag.in b/regress/mdoc/Em/tag.in new file mode 100644 index 00000000..9d309835 --- /dev/null +++ b/regress/mdoc/Em/tag.in @@ -0,0 +1,23 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:05 schwarze Exp $ +.Dd $Mdocdate$ +.Dt EM-TAG 1 +.Os +.Sh NAME +.Nm Em-tag +.Nd tagging of emphasis macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Em one | two +text +.It Xo +.Em three +.Xc +text +.El +.Em four +.Em one +.Tg explicit +.Em five +.Pp +ENDTEST diff --git a/regress/mdoc/Em/tag.out_ascii b/regress/mdoc/Em/tag.out_ascii new file mode 100644 index 00000000..74f8212b --- /dev/null +++ b/regress/mdoc/Em/tag.out_ascii @@ -0,0 +1,17 @@ +EM-TAG(1) General Commands Manual EM-TAG(1) + +NNAAMMEE + EEmm--ttaagg - tagging of emphasis macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + _o_n_e | _t_w_o + text + + _t_h_r_e_e text + _f_o_u_r _o_n_e _f_i_v_e + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Em/tag.out_html b/regress/mdoc/Em/tag.out_html new file mode 100644 index 00000000..4046673f --- /dev/null +++ b/regress/mdoc/Em/tag.out_html @@ -0,0 +1,10 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><i class="Em" id="one">one</i></a> | + <a class="permalink" href="#two"><i class="Em" id="two">two</i></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><i class="Em" id="three">three</i></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><i class="Em" id="four">four</i></a> + <i class="Em">one</i> + <a class="permalink" href="#explicit"><i class="Em" id="explicit">five</i></a> diff --git a/regress/mdoc/Em/tag.out_markdown b/regress/mdoc/Em/tag.out_markdown new file mode 100644 index 00000000..4c107159 --- /dev/null +++ b/regress/mdoc/Em/tag.out_markdown @@ -0,0 +1,25 @@ +EM-TAG(1) - General Commands Manual + +# NAME + +**Em-tag** - tagging of emphasis macros + +# DESCRIPTION + +BEGINTEST + +*one* | *two* + +> text + +*three* + +> text + +*four* +*one* +*five* + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Em/tag.out_tag b/regress/mdoc/Em/tag.out_tag new file mode 100644 index 00000000..c2fbaf59 --- /dev/null +++ b/regress/mdoc/Em/tag.out_tag @@ -0,0 +1,5 @@ +one 9 +two 9 +three 12 +four 13 +explicit 13 diff --git a/regress/mdoc/Er/Makefile b/regress/mdoc/Er/Makefile index 1be2a84a..55f6cc76 100644 --- a/regress/mdoc/Er/Makefile +++ b/regress/mdoc/Er/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.4 2014/07/02 20:18:42 schwarze Exp $ +# $OpenBSD: Makefile,v 1.7 2020/03/13 00:31:05 schwarze Exp $ -REGRESS_TARGETS = noarg font +REGRESS_TARGETS = noarg font tag +TAG_TARGETS = tag LINT_TARGETS = noarg +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Er/tag.in b/regress/mdoc/Er/tag.in new file mode 100644 index 00000000..bad7a88b --- /dev/null +++ b/regress/mdoc/Er/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:05 schwarze Exp $ +.Dd $Mdocdate$ +.Dt ER-TAG 1 +.Os +.Sh NAME +.Nm Er-tag +.Nd tagging of error number macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Er one +text +.El +.Tg +.Er two +.Sh ERRORS +.Bl -tag -width Er +.It Bq Er ENOENT +text +.El +ENDTEST diff --git a/regress/mdoc/Er/tag.out_ascii b/regress/mdoc/Er/tag.out_ascii new file mode 100644 index 00000000..62dbf9ca --- /dev/null +++ b/regress/mdoc/Er/tag.out_ascii @@ -0,0 +1,16 @@ +ER-TAG(1) General Commands Manual ER-TAG(1) + +NNAAMMEE + EErr--ttaagg - tagging of error number macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + one text + two + +EERRRROORRSS + [ENOENT] text + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Er/tag.out_html b/regress/mdoc/Er/tag.out_html new file mode 100644 index 00000000..a2c2978f --- /dev/null +++ b/regress/mdoc/Er/tag.out_html @@ -0,0 +1,12 @@ +<dl class="Bl-tag"> + <dt><code class="Er">one</code></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#two"><code class="Er" id="two">two</code></a> +</section> +<section class="Sh"> +<h1 class="Sh" id="ERRORS"><a class="permalink" href="#ERRORS">ERRORS</a></h1> +<dl class="Bl-tag"> + <dt>[<a class="permalink" href="#ENOENT"><code class="Er" id="ENOENT">ENOENT</code></a>]</dt> + <dd>text</dd> +</dl> diff --git a/regress/mdoc/Er/tag.out_markdown b/regress/mdoc/Er/tag.out_markdown new file mode 100644 index 00000000..d11eb4b9 --- /dev/null +++ b/regress/mdoc/Er/tag.out_markdown @@ -0,0 +1,25 @@ +ER-TAG(1) - General Commands Manual + +# NAME + +**Er-tag** - tagging of error number macros + +# DESCRIPTION + +BEGINTEST + +`one` + +> text + +`two` + +# ERRORS + +\[`ENOENT`] + +> text + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Er/tag.out_tag b/regress/mdoc/Er/tag.out_tag new file mode 100644 index 00000000..b00a6718 --- /dev/null +++ b/regress/mdoc/Er/tag.out_tag @@ -0,0 +1,2 @@ +two 10 +ENOENT 13 diff --git a/regress/mdoc/Ev/Makefile b/regress/mdoc/Ev/Makefile index cfe3ad0b..979e1826 100644 --- a/regress/mdoc/Ev/Makefile +++ b/regress/mdoc/Ev/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.2 2014/07/02 20:18:42 schwarze Exp $ +# $OpenBSD: Makefile,v 1.5 2020/03/13 00:31:05 schwarze Exp $ -REGRESS_TARGETS = font noarg +REGRESS_TARGETS = font noarg tag +TAG_TARGETS = tag LINT_TARGETS = noarg +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Ev/tag.in b/regress/mdoc/Ev/tag.in new file mode 100644 index 00000000..014b0fbc --- /dev/null +++ b/regress/mdoc/Ev/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:05 schwarze Exp $ +.Dd $Mdocdate$ +.Dt EV-TAG 1 +.Os +.Sh NAME +.Nm Ev-tag +.Nd tagging of environment variable macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Ev one | two +text +.It Xo +.Ev three +.Xc +text +.El +.Tg +.Ev four +.Pp +ENDTEST diff --git a/regress/mdoc/Ev/tag.out_ascii b/regress/mdoc/Ev/tag.out_ascii new file mode 100644 index 00000000..5569d1c8 --- /dev/null +++ b/regress/mdoc/Ev/tag.out_ascii @@ -0,0 +1,17 @@ +EV-TAG(1) General Commands Manual EV-TAG(1) + +NNAAMMEE + EEvv--ttaagg - tagging of environment variable macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + one | two + text + + three text + four + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Ev/tag.out_html b/regress/mdoc/Ev/tag.out_html new file mode 100644 index 00000000..1e1c92b9 --- /dev/null +++ b/regress/mdoc/Ev/tag.out_html @@ -0,0 +1,9 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><code class="Ev" id="one">one</code></a> + | + <a class="permalink" href="#two"><code class="Ev" id="two">two</code></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><code class="Ev" id="three">three</code></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><code class="Ev" id="four">four</code></a> diff --git a/regress/mdoc/Ev/tag.out_markdown b/regress/mdoc/Ev/tag.out_markdown new file mode 100644 index 00000000..f9a6712b --- /dev/null +++ b/regress/mdoc/Ev/tag.out_markdown @@ -0,0 +1,23 @@ +EV-TAG(1) - General Commands Manual + +# NAME + +**Ev-tag** - tagging of environment variable macros + +# DESCRIPTION + +BEGINTEST + +`one` | `two` + +> text + +`three` + +> text + +`four` + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Ev/tag.out_tag b/regress/mdoc/Ev/tag.out_tag new file mode 100644 index 00000000..94f0cfb2 --- /dev/null +++ b/regress/mdoc/Ev/tag.out_tag @@ -0,0 +1,4 @@ +one 9 +two 9 +three 12 +four 13 diff --git a/regress/mdoc/Fl/Makefile b/regress/mdoc/Fl/Makefile index e4e4a6bc..c061adef 100644 --- a/regress/mdoc/Fl/Makefile +++ b/regress/mdoc/Fl/Makefile @@ -1,6 +1,9 @@ -# $OpenBSD: Makefile,v 1.13 2020/02/27 01:25:58 schwarze Exp $ +# $OpenBSD: Makefile,v 1.14 2020/03/13 00:31:06 schwarze Exp $ -REGRESS_TARGETS = font multiarg noarg parsed punct spacing +REGRESS_TARGETS = font multiarg noarg parsed punct spacing tag +TAG_TARGETS = tag LINT_TARGETS = punct +HTML_TARGETS = tag +SKIP_TMAN = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Fl/tag.in b/regress/mdoc/Fl/tag.in new file mode 100644 index 00000000..a4d3c135 --- /dev/null +++ b/regress/mdoc/Fl/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt FL-TAG 1 +.Os +.Sh NAME +.Nm Fl-tag +.Nd tagging of command line option macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Fl a | b +text +.It Xo +.Fl c +.Xc +text +.El +.Tg +.Fl d +.Pp +ENDTEST diff --git a/regress/mdoc/Fl/tag.out_ascii b/regress/mdoc/Fl/tag.out_ascii new file mode 100644 index 00000000..4fcf803c --- /dev/null +++ b/regress/mdoc/Fl/tag.out_ascii @@ -0,0 +1,17 @@ +FL-TAG(1) General Commands Manual FL-TAG(1) + +NNAAMMEE + FFll--ttaagg - tagging of command line option macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + --aa | --bb + text + + --cc text + --dd + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Fl/tag.out_html b/regress/mdoc/Fl/tag.out_html new file mode 100644 index 00000000..f67a30c0 --- /dev/null +++ b/regress/mdoc/Fl/tag.out_html @@ -0,0 +1,8 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#a"><code class="Fl" id="a">-a</code></a> | + <a class="permalink" href="#b"><code class="Fl" id="b">-b</code></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#c"><code class="Fl" id="c">-c</code></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#d"><code class="Fl" id="d">-d</code></a> diff --git a/regress/mdoc/Fl/tag.out_markdown b/regress/mdoc/Fl/tag.out_markdown new file mode 100644 index 00000000..1e7c6f14 --- /dev/null +++ b/regress/mdoc/Fl/tag.out_markdown @@ -0,0 +1,23 @@ +FL-TAG(1) - General Commands Manual + +# NAME + +**Fl-tag** - tagging of command line option macros + +# DESCRIPTION + +BEGINTEST + +**-a** | **-b** + +> text + +**-c** + +> text + +**-d** + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Fl/tag.out_tag b/regress/mdoc/Fl/tag.out_tag new file mode 100644 index 00000000..89a94151 --- /dev/null +++ b/regress/mdoc/Fl/tag.out_tag @@ -0,0 +1,4 @@ +a 9 +b 9 +c 12 +d 13 diff --git a/regress/mdoc/Fo/Makefile b/regress/mdoc/Fo/Makefile index 7770e9a1..ce25ddf3 100644 --- a/regress/mdoc/Fo/Makefile +++ b/regress/mdoc/Fo/Makefile @@ -1,8 +1,10 @@ -# $OpenBSD: Makefile,v 1.17 2020/02/27 01:25:58 schwarze Exp $ +# $OpenBSD: Makefile,v 1.18 2020/03/13 00:31:06 schwarze Exp $ REGRESS_TARGETS = basic break eos font noarg nohead -REGRESS_TARGETS += obsolete punct section transp warn +REGRESS_TARGETS += obsolete punct section tag transp warn +TAG_TARGETS = tag LINT_TARGETS = noarg nohead obsolete punct warn +HTML_TARGETS = tag # groff-1.22.3 defects: # - .Fo without an argument prints unbalanced parentheses diff --git a/regress/mdoc/Fo/tag.in b/regress/mdoc/Fo/tag.in new file mode 100644 index 00000000..727fdaf1 --- /dev/null +++ b/regress/mdoc/Fo/tag.in @@ -0,0 +1,29 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt FO-TAG 1 +.Os +.Sh NAME +.Nm Fo-tag +.Nd tagging of function name macros +.Sh DESCRIPTION +BEGINTEST +.Pp +automatic: +.Fn first +and +.Fn second +.Pp +.Fn second +and +.Fn first +.Pp +explicit: +.Tg e3 +.Fn third +and +.Tg e4 +.Fo fourth +.Fa void +.Fc +.Pp +ENDTEST diff --git a/regress/mdoc/Fo/tag.out_ascii b/regress/mdoc/Fo/tag.out_ascii new file mode 100644 index 00000000..505c0b7a --- /dev/null +++ b/regress/mdoc/Fo/tag.out_ascii @@ -0,0 +1,17 @@ +FO-TAG(1) General Commands Manual FO-TAG(1) + +NNAAMMEE + FFoo--ttaagg - tagging of function name macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + automatic: ffiirrsstt() and sseeccoonndd() + + sseeccoonndd() and ffiirrsstt() + + explicit: tthhiirrdd() and ffoouurrtthh(_v_o_i_d) + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Fo/tag.out_html b/regress/mdoc/Fo/tag.out_html new file mode 100644 index 00000000..b3508614 --- /dev/null +++ b/regress/mdoc/Fo/tag.out_html @@ -0,0 +1,9 @@ +<p class="Pp">automatic: + <a class="permalink" href="#first"><code class="Fn" id="first">first</code></a>() + and <code class="Fn">second</code>()</p> +<p class="Pp"><a class="permalink" href="#second"><code class="Fn" id="second">second</code></a>() + and <code class="Fn">first</code>()</p> +<p class="Pp">explicit: + <a class="permalink" href="#e3"><code class="Fn" id="e3">third</code></a>() + and + <a class="permalink" href="#e4"><code class="Fn" id="e4">fourth</code></a>(<var class="Fa">void</var>);</p> diff --git a/regress/mdoc/Fo/tag.out_markdown b/regress/mdoc/Fo/tag.out_markdown new file mode 100644 index 00000000..273a00d4 --- /dev/null +++ b/regress/mdoc/Fo/tag.out_markdown @@ -0,0 +1,27 @@ +FO-TAG(1) - General Commands Manual + +# NAME + +**Fo-tag** - tagging of function name macros + +# DESCRIPTION + +BEGINTEST + +automatic: +**first**() +and +**second**() + +**second**() +and +**first**() + +explicit: +**third**() +and +**fourth**(*void*) + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Fo/tag.out_tag b/regress/mdoc/Fo/tag.out_tag new file mode 100644 index 00000000..2387023c --- /dev/null +++ b/regress/mdoc/Fo/tag.out_tag @@ -0,0 +1,4 @@ +first 9 +second 11 +e3 13 +e4 13 diff --git a/regress/mdoc/Ic/Makefile b/regress/mdoc/Ic/Makefile index 33faa380..4a06ee20 100644 --- a/regress/mdoc/Ic/Makefile +++ b/regress/mdoc/Ic/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.4 2014/07/02 20:18:42 schwarze Exp $ +# $OpenBSD: Makefile,v 1.8 2020/03/13 00:31:06 schwarze Exp $ -REGRESS_TARGETS = font noarg punct +REGRESS_TARGETS = font noarg punct tag +TAG_TARGETS = tag LINT_TARGETS = noarg +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Ic/tag.in b/regress/mdoc/Ic/tag.in new file mode 100644 index 00000000..fb7b441e --- /dev/null +++ b/regress/mdoc/Ic/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt IC-TAG 1 +.Os +.Sh NAME +.Nm Ic-tag +.Nd tagging of internal command macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Ic one | two +text +.It Xo +.Ic three +.Xc +text +.El +.Tg +.Ic four +.Pp +ENDTEST diff --git a/regress/mdoc/Ic/tag.out_ascii b/regress/mdoc/Ic/tag.out_ascii new file mode 100644 index 00000000..513b2638 --- /dev/null +++ b/regress/mdoc/Ic/tag.out_ascii @@ -0,0 +1,17 @@ +IC-TAG(1) General Commands Manual IC-TAG(1) + +NNAAMMEE + IIcc--ttaagg - tagging of internal command macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + oonnee | ttwwoo + text + + tthhrreeee text + ffoouurr + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Ic/tag.out_html b/regress/mdoc/Ic/tag.out_html new file mode 100644 index 00000000..ad3cc1ef --- /dev/null +++ b/regress/mdoc/Ic/tag.out_html @@ -0,0 +1,9 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><code class="Ic" id="one">one</code></a> + | + <a class="permalink" href="#two"><code class="Ic" id="two">two</code></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><code class="Ic" id="three">three</code></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><code class="Ic" id="four">four</code></a> diff --git a/regress/mdoc/Ic/tag.out_markdown b/regress/mdoc/Ic/tag.out_markdown new file mode 100644 index 00000000..c0f13879 --- /dev/null +++ b/regress/mdoc/Ic/tag.out_markdown @@ -0,0 +1,23 @@ +IC-TAG(1) - General Commands Manual + +# NAME + +**Ic-tag** - tagging of internal command macros + +# DESCRIPTION + +BEGINTEST + +**one** | **two** + +> text + +**three** + +> text + +**four** + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Ic/tag.out_tag b/regress/mdoc/Ic/tag.out_tag new file mode 100644 index 00000000..94f0cfb2 --- /dev/null +++ b/regress/mdoc/Ic/tag.out_tag @@ -0,0 +1,4 @@ +one 9 +two 9 +three 12 +four 13 diff --git a/regress/mdoc/Li/Makefile b/regress/mdoc/Li/Makefile index 7b2a3313..44dcf01c 100644 --- a/regress/mdoc/Li/Makefile +++ b/regress/mdoc/Li/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.7 2018/12/21 16:58:49 schwarze Exp $ +# $OpenBSD: Makefile,v 1.8 2020/03/13 00:31:06 schwarze Exp $ -REGRESS_TARGETS = arg punct font +REGRESS_TARGETS = arg punct font tag +TAG_TARGETS = tag LINT_TARGETS = punct +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Li/tag.in b/regress/mdoc/Li/tag.in new file mode 100644 index 00000000..add672ad --- /dev/null +++ b/regress/mdoc/Li/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt LI-TAG 1 +.Os +.Sh NAME +.Nm Li-tag +.Nd tagging of literal font macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Li one | two +text +.It Xo +.Li three +.Xc +text +.El +.Tg +.Li four +.Pp +ENDTEST diff --git a/regress/mdoc/Li/tag.out_ascii b/regress/mdoc/Li/tag.out_ascii new file mode 100644 index 00000000..e1afda6e --- /dev/null +++ b/regress/mdoc/Li/tag.out_ascii @@ -0,0 +1,17 @@ +LI-TAG(1) General Commands Manual LI-TAG(1) + +NNAAMMEE + LLii--ttaagg - tagging of literal font macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + one | two + text + + three text + four + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Li/tag.out_html b/regress/mdoc/Li/tag.out_html new file mode 100644 index 00000000..3730caa6 --- /dev/null +++ b/regress/mdoc/Li/tag.out_html @@ -0,0 +1,9 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><code class="Li" id="one">one</code></a> + | + <a class="permalink" href="#two"><code class="Li" id="two">two</code></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><code class="Li" id="three">three</code></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><code class="Li" id="four">four</code></a> diff --git a/regress/mdoc/Li/tag.out_markdown b/regress/mdoc/Li/tag.out_markdown new file mode 100644 index 00000000..6467e16d --- /dev/null +++ b/regress/mdoc/Li/tag.out_markdown @@ -0,0 +1,23 @@ +LI-TAG(1) - General Commands Manual + +# NAME + +**Li-tag** - tagging of literal font macros + +# DESCRIPTION + +BEGINTEST + +`one` | `two` + +> text + +`three` + +> text + +`four` + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Li/tag.out_tag b/regress/mdoc/Li/tag.out_tag new file mode 100644 index 00000000..94f0cfb2 --- /dev/null +++ b/regress/mdoc/Li/tag.out_tag @@ -0,0 +1,4 @@ +one 9 +two 9 +three 12 +four 13 diff --git a/regress/mdoc/Makefile b/regress/mdoc/Makefile index 86bdcb7a..83bd7fb7 100644 --- a/regress/mdoc/Makefile +++ b/regress/mdoc/Makefile @@ -1,9 +1,9 @@ -# $OpenBSD: Makefile,v 1.32 2017/01/11 17:39:45 schwarze Exp $ +# $OpenBSD: Makefile,v 1.33 2020/03/13 00:31:05 schwarze Exp $ SUBDIR = Ad An Ap Aq Ar At Bd Bf Bk Bl Brq Bx Cd Cm SUBDIR += D1 Db Dd Dl Dq Dt Dv Em Eo Er Ev Ex Fd Fl Fo Ft Ic In Lb Li Lk SUBDIR += Ms Mt Nd Nm No Ns Oo Op Os Ox Pa Pf Pp Qq Rs Rv -SUBDIR += Sh Sm Sq St Sx Sy Tn Ud Ux Va Vt Xr blank break +SUBDIR += Sh Sm Sq St Sx Sy Tg Tn Ud Ux Va Vt Xr blank break .include "../Makefile.sub" .include <bsd.subdir.mk> diff --git a/regress/mdoc/Ms/Makefile b/regress/mdoc/Ms/Makefile index 1be2a84a..618edd3f 100644 --- a/regress/mdoc/Ms/Makefile +++ b/regress/mdoc/Ms/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.4 2014/07/02 20:18:42 schwarze Exp $ +# $OpenBSD: Makefile,v 1.8 2020/03/13 00:58:48 schwarze Exp $ -REGRESS_TARGETS = noarg font +REGRESS_TARGETS = noarg font tag +TAG_TARGETS = tag LINT_TARGETS = noarg +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Ms/tag.in b/regress/mdoc/Ms/tag.in new file mode 100644 index 00000000..e3465073 --- /dev/null +++ b/regress/mdoc/Ms/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt MS-TAG 1 +.Os +.Sh NAME +.Nm Ms-tag +.Nd tagging of mathematical symbol macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Ms one | two +text +.It Xo +.Ms three +.Xc +text +.El +.Tg +.Ms four +.Pp +ENDTEST diff --git a/regress/mdoc/Ms/tag.out_ascii b/regress/mdoc/Ms/tag.out_ascii new file mode 100644 index 00000000..2d06f4bf --- /dev/null +++ b/regress/mdoc/Ms/tag.out_ascii @@ -0,0 +1,17 @@ +MS-TAG(1) General Commands Manual MS-TAG(1) + +NNAAMMEE + MMss--ttaagg - tagging of mathematical symbol macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + oonnee | ttwwoo + text + + tthhrreeee text + ffoouurr + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Ms/tag.out_html b/regress/mdoc/Ms/tag.out_html new file mode 100644 index 00000000..0f24b2ac --- /dev/null +++ b/regress/mdoc/Ms/tag.out_html @@ -0,0 +1,9 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><span class="Ms" id="one">one</span></a> + | + <a class="permalink" href="#two"><span class="Ms" id="two">two</span></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><span class="Ms" id="three">three</span></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><span class="Ms" id="four">four</span></a> diff --git a/regress/mdoc/Ms/tag.out_markdown b/regress/mdoc/Ms/tag.out_markdown new file mode 100644 index 00000000..055c3860 --- /dev/null +++ b/regress/mdoc/Ms/tag.out_markdown @@ -0,0 +1,23 @@ +MS-TAG(1) - General Commands Manual + +# NAME + +**Ms-tag** - tagging of mathematical symbol macros + +# DESCRIPTION + +BEGINTEST + +**one** | **two** + +> text + +**three** + +> text + +**four** + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Ms/tag.out_tag b/regress/mdoc/Ms/tag.out_tag new file mode 100644 index 00000000..94f0cfb2 --- /dev/null +++ b/regress/mdoc/Ms/tag.out_tag @@ -0,0 +1,4 @@ +one 9 +two 9 +three 12 +four 13 diff --git a/regress/mdoc/No/Makefile b/regress/mdoc/No/Makefile index 3110bf2b..35aa4e1e 100644 --- a/regress/mdoc/No/Makefile +++ b/regress/mdoc/No/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.4 2014/11/17 06:44:35 schwarze Exp $ +# $OpenBSD: Makefile,v 1.7 2020/03/13 00:31:06 schwarze Exp $ -REGRESS_TARGETS = punct spacing +REGRESS_TARGETS = punct spacing tag +TAG_TARGETS = tag LINT_TARGETS = punct +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/No/punct.out_lint b/regress/mdoc/No/punct.out_lint index e046da6a..6a65c3b4 100644 --- a/regress/mdoc/No/punct.out_lint +++ b/regress/mdoc/No/punct.out_lint @@ -23,3 +23,4 @@ mandoc: punct.in:72:7: WARNING: skipping empty macro: No mandoc: punct.in:75:7: WARNING: skipping empty macro: No mandoc: punct.in:76:7: WARNING: skipping empty macro: No mandoc: punct.in:84:2: WARNING: skipping empty macro: No +mandoc: punct.in:87:6: STYLE: no blank before trailing delimiter: No a. diff --git a/regress/mdoc/No/tag.in b/regress/mdoc/No/tag.in new file mode 100644 index 00000000..700d79da --- /dev/null +++ b/regress/mdoc/No/tag.in @@ -0,0 +1,21 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt NO-TAG 1 +.Os +.Sh NAME +.Nm No-tag +.Nd tagging of normal font macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It No one | two +text +.It Xo +.No three +.Xc +text +.El +.Tg +.No four +.Pp +ENDTEST diff --git a/regress/mdoc/No/tag.out_ascii b/regress/mdoc/No/tag.out_ascii new file mode 100644 index 00000000..44481b02 --- /dev/null +++ b/regress/mdoc/No/tag.out_ascii @@ -0,0 +1,17 @@ +NO-TAG(1) General Commands Manual NO-TAG(1) + +NNAAMMEE + NNoo--ttaagg - tagging of normal font macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + one | two + text + + three text + four + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/No/tag.out_html b/regress/mdoc/No/tag.out_html new file mode 100644 index 00000000..32696917 --- /dev/null +++ b/regress/mdoc/No/tag.out_html @@ -0,0 +1,9 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><span class="No" id="one">one</span></a> + | + <a class="permalink" href="#two"><span class="No" id="two">two</span></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><span class="No" id="three">three</span></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><span class="No" id="four">four</span></a> diff --git a/regress/mdoc/No/tag.out_markdown b/regress/mdoc/No/tag.out_markdown new file mode 100644 index 00000000..1590c010 --- /dev/null +++ b/regress/mdoc/No/tag.out_markdown @@ -0,0 +1,23 @@ +NO-TAG(1) - General Commands Manual + +# NAME + +**No-tag** - tagging of normal font macros + +# DESCRIPTION + +BEGINTEST + +one | two + +> text + +three + +> text + +four + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/No/tag.out_tag b/regress/mdoc/No/tag.out_tag new file mode 100644 index 00000000..94f0cfb2 --- /dev/null +++ b/regress/mdoc/No/tag.out_tag @@ -0,0 +1,4 @@ +one 9 +two 9 +three 12 +four 13 diff --git a/regress/mdoc/Sy/Makefile b/regress/mdoc/Sy/Makefile index 36c1859b..752d1382 100644 --- a/regress/mdoc/Sy/Makefile +++ b/regress/mdoc/Sy/Makefile @@ -1,6 +1,8 @@ -# $OpenBSD: Makefile,v 1.5 2014/11/17 06:44:35 schwarze Exp $ +# $OpenBSD: Makefile,v 1.8 2020/03/13 00:31:06 schwarze Exp $ -REGRESS_TARGETS = noarg font punct +REGRESS_TARGETS = noarg font punct tag +TAG_TARGETS = tag LINT_TARGETS = noarg punct +HTML_TARGETS = tag .include <bsd.regress.mk> diff --git a/regress/mdoc/Sy/tag.in b/regress/mdoc/Sy/tag.in new file mode 100644 index 00000000..b2719093 --- /dev/null +++ b/regress/mdoc/Sy/tag.in @@ -0,0 +1,23 @@ +.\" $OpenBSD: tag.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt SY-TAG 1 +.Os +.Sh NAME +.Nm Sy-tag +.Nd tagging of symbolic font macros +.Sh DESCRIPTION +BEGINTEST +.Bl -tag -width Ds +.It Sy one | two +text +.It Xo +.Sy three +.Xc +text +.El +.Sy four +.Sy one +.Tg explicit +.Sy five +.Pp +ENDTEST diff --git a/regress/mdoc/Sy/tag.out_ascii b/regress/mdoc/Sy/tag.out_ascii new file mode 100644 index 00000000..3b89cb41 --- /dev/null +++ b/regress/mdoc/Sy/tag.out_ascii @@ -0,0 +1,17 @@ +SY-TAG(1) General Commands Manual SY-TAG(1) + +NNAAMMEE + SSyy--ttaagg - tagging of symbolic font macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + oonnee | ttwwoo + text + + tthhrreeee text + ffoouurr oonnee ffiivvee + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Sy/tag.out_html b/regress/mdoc/Sy/tag.out_html new file mode 100644 index 00000000..69276a18 --- /dev/null +++ b/regress/mdoc/Sy/tag.out_html @@ -0,0 +1,10 @@ +<dl class="Bl-tag"> + <dt><a class="permalink" href="#one"><b class="Sy" id="one">one</b></a> | + <a class="permalink" href="#two"><b class="Sy" id="two">two</b></a></dt> + <dd>text</dd> + <dt><a class="permalink" href="#three"><b class="Sy" id="three">three</b></a></dt> + <dd>text</dd> +</dl> +<a class="permalink" href="#four"><b class="Sy" id="four">four</b></a> + <b class="Sy">one</b> + <a class="permalink" href="#explicit"><b class="Sy" id="explicit">five</b></a> diff --git a/regress/mdoc/Sy/tag.out_markdown b/regress/mdoc/Sy/tag.out_markdown new file mode 100644 index 00000000..5382a5e2 --- /dev/null +++ b/regress/mdoc/Sy/tag.out_markdown @@ -0,0 +1,25 @@ +SY-TAG(1) - General Commands Manual + +# NAME + +**Sy-tag** - tagging of symbolic font macros + +# DESCRIPTION + +BEGINTEST + +**one** | **two** + +> text + +**three** + +> text + +**four** +**one** +**five** + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Sy/tag.out_tag b/regress/mdoc/Sy/tag.out_tag new file mode 100644 index 00000000..c2fbaf59 --- /dev/null +++ b/regress/mdoc/Sy/tag.out_tag @@ -0,0 +1,5 @@ +one 9 +two 9 +three 12 +four 13 +explicit 13 diff --git a/regress/mdoc/Tg/Makefile b/regress/mdoc/Tg/Makefile new file mode 100644 index 00000000..7f538766 --- /dev/null +++ b/regress/mdoc/Tg/Makefile @@ -0,0 +1,8 @@ +# $OpenBSD: Makefile,v 1.1 2020/03/13 00:31:06 schwarze Exp $ + +REGRESS_TARGETS = warn +TAG_TARGETS = warn +LINT_TARGETS = warn +HTML_TARGETS = warn + +.include <bsd.regress.mk> diff --git a/regress/mdoc/Tg/warn.in b/regress/mdoc/Tg/warn.in new file mode 100644 index 00000000..af40f012 --- /dev/null +++ b/regress/mdoc/Tg/warn.in @@ -0,0 +1,34 @@ +.\" $OpenBSD: warn.in,v 1.1 2020/03/13 00:31:06 schwarze Exp $ +.Dd $Mdocdate$ +.Dt TG-WARN 1 +.Os +.Sh NAME +.Nm Tg-warn +.Nd warnings about tagging macros +.Sh DESCRIPTION +BEGINTEST +.Pp +.Tg start +initial +text +.Tg +.Ic macro +.Tg "" ignored arguments +too many +.Tg \&badstart +badstart +.Tg badend\& +badend +.Tg "white space" +whitespace +.Tg sub +.Tg double +.Ss Subsection +subtext +.Tg examples +.Sh EXAMPLES +example +text +.Pp +ENDTEST +.Tg diff --git a/regress/mdoc/Tg/warn.out_ascii b/regress/mdoc/Tg/warn.out_ascii new file mode 100644 index 00000000..8dee9aed --- /dev/null +++ b/regress/mdoc/Tg/warn.out_ascii @@ -0,0 +1,19 @@ +TG-WARN(1) General Commands Manual TG-WARN(1) + +NNAAMMEE + TTgg--wwaarrnn - warnings about tagging macros + +DDEESSCCRRIIPPTTIIOONN + BEGINTEST + + initial text mmaaccrroo too many badstart badend whitespace + + SSuubbsseeccttiioonn + subtext + +EEXXAAMMPPLLEESS + example text + + ENDTEST + +OpenBSD March 13, 2020 OpenBSD diff --git a/regress/mdoc/Tg/warn.out_html b/regress/mdoc/Tg/warn.out_html new file mode 100644 index 00000000..b4d3cf74 --- /dev/null +++ b/regress/mdoc/Tg/warn.out_html @@ -0,0 +1,11 @@ +<p class="Pp"><mark id="start"></mark>initial text + <a class="permalink" href="#macro"><code class="Ic" id="macro">macro</code></a> + too many badstart badend whitespace <mark id="sub"></mark></p> +<section class="Ss"> +<h2 class="Ss" id="double"><a class="permalink" href="#double">Subsection</a></h2> +<p class="Pp">subtext</p> +</section> +</section> +<section class="Sh"> +<h1 class="Sh" id="examples"><a class="permalink" href="#examples">EXAMPLES</a></h1> +<p class="Pp">example text</p> diff --git a/regress/mdoc/Tg/warn.out_lint b/regress/mdoc/Tg/warn.out_lint new file mode 100644 index 00000000..39c1f541 --- /dev/null +++ b/regress/mdoc/Tg/warn.out_lint @@ -0,0 +1,6 @@ +mandoc: warn.in:16:2: WARNING: skipping empty macro: Tg +mandoc: warn.in:16:8: ERROR: skipping excess arguments: Tg ... ignored +mandoc: warn.in:18:5: ERROR: skipping tag containing whitespace: Tg \&badstart +mandoc: warn.in:20:11: ERROR: skipping tag containing whitespace: Tg badend\& +mandoc: warn.in:22:10: ERROR: skipping tag containing whitespace: Tg white space +mandoc: warn.in:34:2: WARNING: skipping empty macro: Tg diff --git a/regress/mdoc/Tg/warn.out_markdown b/regress/mdoc/Tg/warn.out_markdown new file mode 100644 index 00000000..87204424 --- /dev/null +++ b/regress/mdoc/Tg/warn.out_markdown @@ -0,0 +1,30 @@ +TG-WARN(1) - General Commands Manual + +# NAME + +**Tg-warn** - warnings about tagging macros + +# DESCRIPTION + +BEGINTEST + +initial +text +**macro** +too many +badstart +badend +whitespace + +## Subsection + +subtext + +# EXAMPLES + +example +text + +ENDTEST + +OpenBSD - March 13, 2020 diff --git a/regress/mdoc/Tg/warn.out_tag b/regress/mdoc/Tg/warn.out_tag new file mode 100644 index 00000000..e1fc141c --- /dev/null +++ b/regress/mdoc/Tg/warn.out_tag @@ -0,0 +1,5 @@ +start 9 +macro 9 +sub 9 +double 11 +examples 14 |