summaryrefslogtreecommitdiffstats
path: root/regress/man
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2018-12-04 02:53:51 +0000
committerIngo Schwarze <schwarze@openbsd.org>2018-12-04 02:53:51 +0000
commitd5e1ccb6de73cd87d11400b2f3d09826595bfc89 (patch)
tree16a922eb7f5a41bc2ef3f86d153377b0258a8cfa /regress/man
parentd504e7480ce979e924b1c4fe82bdbcaa790ca153 (diff)
downloadmandoc-d5e1ccb6de73cd87d11400b2f3d09826595bfc89.tar.gz
Clean up the validation of .Pp, .PP, .sp, and .br. Make sure all
combinations are handled, and are handled in a systematic manner. This resolves some erratic duplicate handling, handles a number of missing cases, and improves diagnostics in various respects. Move validation of .br and .sp to the roff validation module rather than doing that twice in the mdoc and man validation modules. Move the node relinking function to the roff library where it belongs. In validation functions, only look at the node itself, at previous nodes, and at descendants, not at following nodes or ancestors, such that only nodes are inspected which are already validated.
Diffstat (limited to 'regress/man')
-rw-r--r--regress/man/PP/empty.out_lint1
-rw-r--r--regress/man/blank/afterSH.out_lint2
-rw-r--r--regress/man/blank/afterSS.out_lint2
-rw-r--r--regress/man/blank/line.out_lint9
4 files changed, 12 insertions, 2 deletions
diff --git a/regress/man/PP/empty.out_lint b/regress/man/PP/empty.out_lint
index 4c62912f..2a8516ac 100644
--- a/regress/man/PP/empty.out_lint
+++ b/regress/man/PP/empty.out_lint
@@ -1,3 +1,4 @@
mandoc: empty.in:8:2: WARNING: skipping paragraph macro: PP empty
mandoc: empty.in:11:2: WARNING: skipping paragraph macro: PP empty
mandoc: empty.in:14:2: WARNING: skipping paragraph macro: PP empty
+mandoc: empty.in:6:2: WARNING: skipping paragraph macro: PP after SH
diff --git a/regress/man/blank/afterSH.out_lint b/regress/man/blank/afterSH.out_lint
index 4f641b3c..233661d6 100644
--- a/regress/man/blank/afterSH.out_lint
+++ b/regress/man/blank/afterSH.out_lint
@@ -1,4 +1,6 @@
+mandoc: afterSH.in:10:2: WARNING: skipping paragraph macro: PP after SH
mandoc: afterSH.in:32:2: WARNING: skipping paragraph macro: br after SH
mandoc: afterSH.in:36:2: WARNING: skipping paragraph macro: sp after SH
+mandoc: afterSH.in:45:2: WARNING: skipping paragraph macro: PP after SH
mandoc: afterSH.in:72:2: WARNING: skipping paragraph macro: br after SH
mandoc: afterSH.in:77:2: WARNING: skipping paragraph macro: sp after SH
diff --git a/regress/man/blank/afterSS.out_lint b/regress/man/blank/afterSS.out_lint
index e5f5bc47..0204890c 100644
--- a/regress/man/blank/afterSS.out_lint
+++ b/regress/man/blank/afterSS.out_lint
@@ -1,4 +1,6 @@
+mandoc: afterSS.in:11:2: WARNING: skipping paragraph macro: PP after SS
mandoc: afterSS.in:33:2: WARNING: skipping paragraph macro: br after SS
mandoc: afterSS.in:37:2: WARNING: skipping paragraph macro: sp after SS
+mandoc: afterSS.in:46:2: WARNING: skipping paragraph macro: PP after SS
mandoc: afterSS.in:73:2: WARNING: skipping paragraph macro: br after SS
mandoc: afterSS.in:78:2: WARNING: skipping paragraph macro: sp after SS
diff --git a/regress/man/blank/line.out_lint b/regress/man/blank/line.out_lint
index 30de6f49..28a6898a 100644
--- a/regress/man/blank/line.out_lint
+++ b/regress/man/blank/line.out_lint
@@ -1,8 +1,13 @@
-mandoc: line.in:6:2: WARNING: skipping paragraph macro: sp after SH
+mandoc: line.in:18:2: WARNING: skipping paragraph macro: br after br
mandoc: line.in:24:2: WARNING: skipping paragraph macro: br after PP
mandoc: line.in:26:2: WARNING: skipping paragraph macro: PP empty
+mandoc: line.in:29:2: WARNING: skipping paragraph macro: br before sp
+mandoc: line.in:33:2: WARNING: skipping paragraph macro: br after sp
mandoc: line.in:36:2: WARNING: skipping paragraph macro: sp after PP
mandoc: line.in:39:2: WARNING: skipping paragraph macro: sp after PP
+mandoc: line.in:47:2: WARNING: skipping paragraph macro: br before sp
+mandoc: line.in:51:2: WARNING: skipping paragraph macro: br after sp
mandoc: line.in:54:1: WARNING: skipping paragraph macro: sp after PP
-mandoc: line.in:82:2: WARNING: skipping paragraph macro: sp after SH
+mandoc: line.in:6:2: WARNING: skipping paragraph macro: sp after SH
mandoc: line.in:85:2: WARNING: skipping paragraph macro: sp after SS
+mandoc: line.in:82:2: WARNING: skipping paragraph macro: sp after SH