aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/regress/roff
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
commitb8c7224b007d9673c637669ba26ff55f38effe12 (patch)
tree27d1ed6e0ae499cceea05feaef09d6f683d86fdd /regress/roff
parent820b4d56427ff6a0f1e3399ac7e4aea447dd5c20 (diff)
downloadmandoc-b8c7224b007d9673c637669ba26ff55f38effe12.tar.gz
mandoc-b8c7224b007d9673c637669ba26ff55f38effe12.tar.zst
mandoc-b8c7224b007d9673c637669ba26ff55f38effe12.zip
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/roff')
-rw-r--r--regress/roff/args/roff.out_lint1
-rw-r--r--regress/roff/cond/if.out_lint2
2 files changed, 3 insertions, 0 deletions
diff --git a/regress/roff/args/roff.out_lint b/regress/roff/args/roff.out_lint
index 5ac03917..c5f4b3d3 100644
--- a/regress/roff/args/roff.out_lint
+++ b/regress/roff/args/roff.out_lint
@@ -14,3 +14,4 @@ mandoc: roff.in:69:7: STYLE: unterminated quoted argument
mandoc: roff.in:69:13: STYLE: whitespace at end of input line
mandoc: roff.in:70:11: STYLE: unterminated quoted argument
mandoc: roff.in:70:17: STYLE: whitespace at end of input line
+mandoc: roff.in:72:2: WARNING: skipping paragraph macro: br at the end of SH
diff --git a/regress/roff/cond/if.out_lint b/regress/roff/cond/if.out_lint
index 5fb37795..597140d8 100644
--- a/regress/roff/cond/if.out_lint
+++ b/regress/roff/cond/if.out_lint
@@ -1,2 +1,4 @@
mandoc: if.in:15:2: WARNING: conditional request controls empty scope: if
mandoc: if.in:17:2: WARNING: conditional request controls empty scope: if
+mandoc: if.in:42:2: WARNING: skipping paragraph macro: br before sp
+mandoc: if.in:71:2: WARNING: skipping paragraph macro: br after br